-
Notifications
You must be signed in to change notification settings - Fork 640
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
Save nunjuck env reference in express app settings #829
Conversation
@@ -286,6 +286,7 @@ var Environment = Obj.extend({ | |||
}; | |||
|
|||
app.set('view', NunjucksView); | |||
app.set('nunjuckEnv', this); |
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.
Its nunjucks, with the s
, so this should be nunjucksEnv
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.
Sorted 👍
Can you add a test for this? |
I've added what I think should be a passing test but I'm not quite sure how to run the express tests. |
Huh, looks like the express tests aren't running. Odd. I'll create a separate issue for that. Test looks fine, anyway, I'll go with it for now. |
* Save nunjuck env reference in express app settings * Add test for express nunjucks env reference
@carljm Yeah, it definitely works, I've manually copied this version into Don't mean to rush you, sure you're busy, but just wondering if you had any plans to release this on npm soon? I'm currently working on a time sensitive project and it would be awesome to be able to get rid of my current workaround from the issue I posted. |
I'll try to make a release soon. |
@vecmezoni great to see you've stepped up to help maintain this project. I just noticed you've published a new build to npm. Is there any chance you could publish a version with this PR in? |
@lukechilds ok, tomorrow i'll check 2.x branch and publish 2.5.0 😉 |
That would be amazing, thank you! 🍻 |
@lukechilds can't wait till tomorrow, published 2.5.0 with this PR. |
@vecmezoni working perfectly, cheers. |
Resolves #828