@see https://timber.github.io/docs/v1/getting-started/switch-to-composer/
Remove from your composer.json
"wpackagist-plugin/timber-library": "version_here",
Run
composer require timber/timber:^1.0
Several calls need to use:
use Timber\Timber;
use Timber\Post as TimberPost;
Some PHP calls:
- return \Timber::get_posts($args);
+ return Timber::get_posts($args);
Making sure that the right twig folder is used:
- Timber::$dirname = array('templates', 'views');
+ $timber = new Timber\Timber();
+ // https://timber.github.io/docs/v1/guides/template-locations/
+ Timber::$dirname = [ 'templates' ];
Leave a Reply