-
Notifications
You must be signed in to change notification settings - Fork 157
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
Is it possible render template without $data param? #312
Comments
If your template does not need any data, then it's just plain HTML, no? If so, just serve that file statically, |
@simonpersson I guess I will use the case is home page(like index.tpl). |
I think setting the |
Yep, but it's quite inconvenient. I know I ran into this myself before and we had a discussion on exactly that. Not sure about the right way forward but there should be a simple way to render a template without data, without explicitly setting the |
@Ryman @cburgdorf |
Hi there.
I always watch sample
render
method with$data
but, I can't find wihtoout
$data
param.is best.
but,
render
method's 2nd param is not optionalSo, I always set dummy data....
However it isn't possible
return res.render("src/templates/main.tpl", &[[);
The text was updated successfully, but these errors were encountered: