New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
View::render and View::display not rendering variable #6
Comments
did you try View::render('template.twig', array('name' => 'John')); |
since View::render return the rendered view, I use echo here echo View::render('template.twig', array('name' => 'John')); but it give the same result, no variable passed you can clone this repo to reproduce the issue _edit_ I am trying App::render('template.twig', $data) and it also workd |
Hey, this is actually an upstream bug in the Twig view, I've sent a pull request with a fix slimphp/Slim-Views#21. |
Hi, I see your pull request was merged to upstream repo, but it is in develop branch. until it merged to the master branch, I think I can go with edit |
Hi,
I am trying to implement twig as slim view renderer,
when I am using Slim-facade to render a view, variable is not passed to the view
template.twig
the routes.php
I am using this code to initiate Slim, slim-facades, and twig
The text was updated successfully, but these errors were encountered: