-
Notifications
You must be signed in to change notification settings - Fork 11
Pass options to Nunjucks directly #50
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉 👍
I thought, maybe, it should be specific option like |
Yeap, I hesitate around that thought too. |
Btw, can we merge this into 2.x branch too? |
Maybe, not doing this is a good way to move people forward :) Are you sure this is a must have feature? |
There is a critical bug in Nunjucks 3.x due to which we can't move from 2.x. It hasn't been fixed for almost a year... But we'd like to enable cache in 2.x. Well, I think it's more like a personal requirement, since not much people will encounter that bug, so I'll probably just make temporary fork of master and lower version to 2.x |
I think you can make a pr into v2.x, I'll merge it.
ср, 14 июня 2017 г. в 14:41, Serj Lavrin <[email protected]>:
… There is a critical bug in Nunjucks 3.x due to which we can't move from
2.x. It hasn't been fixed for almost a year... But we'd like to enable
cache in 2.x.
Well, I think it's more like a personal requirement, since not much people
will encounter that bug, so I'll probably just make temporary fork of
master and lower version to 2.x
—
You are receiving this because you modified the open/close state.
Reply to this email directly, view it on GitHub
<#50 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AC3Nv_1EyXqi9wH2WqvKiHNd5pVHtM-Tks5sD8bWgaJpZM4N4ghT>
.
|
I would do it by myself if I had the feature branch in this repo, but it's in your fork, I'm sorry. |
There is no reason to cherry pick only certain options which will be passed from
this.options()
tonunjucks.configure()
.Instead, we can brutally pass all options directly to
nunjucks.configure()
. Yes, sometimes it will also pass not relevant tonunjucks
options likeconfigureEnvironment
and so on, but since Nunjucks doesn't know anything about them, they will be simply ignored.This change will allows us to rest assured that users will be always able to pass environment configurations to Nunjucks, no matter what API changes will happen in Nunjucks.
Also, it will allow users to change options they wanted to change. For instance, right now we've hardcoded
noChache: true
and users wasn't able to enable cache whenever they needed it.