php - Do I have to use twig with Silex? -
do have use twig render views in silex or able render views , code them via pure php rather template engine? if so, how go doing it?
thanks!
no, silex not force use twig, or mandate template engine @ matter.
generally way you'd use template engine (or library) silex is:
- add library
composer.json
install it. - set library silex di container. if pre-packaged silex service provider exists, can use wire in container.
- access templating service, either fetching container yourself, or defining service receives service constructor argument.
Comments
Post a Comment