Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

odd one-off improvements #99

wants to merge 3 commits into


None yet
4 participants


My office uses RazorEngine for one of our web applications. We have recently updated to version 3.2.0. For our use we required a few minor improvements / extensions to the RazorEngine API. I've created a pull request containing these minor improvements, please feel free to cherry-pick them or accept all as you desire.

-Gordon Burgett

gburgett added some commits Mar 26, 2013

@gburgett gburgett add overridable before and after execute on TemplateBase
Signed-off-by: Gordon Burgett <gordon.burgett@gmail.com>
@gburgett gburgett allow templatebase subclasses to override setModel, permitting model …
…types which may not equal T.

Signed-off-by: Gordon Burgett <gordon.burgett@gmail.com>
@gburgett gburgett allow linking multiple cacheName keys to the same template
Signed-off-by: Gordon Burgett <gordon.burgett@gmail.com>

@Antaris I recommend merging these improvements in your master. They have been very useful to me!


Antaris commented Jan 21, 2014

I'll review these changes this week and try and migrate them in. They look useful! Also, I am looking to seperate the caching mechanism from the main TemplateService instance so cached templates can be shared between instances of TemplateService and potentially allow for cached assemblies to be written to disk.


matthid commented Dec 13, 2014

Could you please rebase your changes on top of the current master branch?

Can you describe in what situations you want to duplicate a cacheName?


matthid commented Dec 30, 2014

I'm closing this as we now have SetModel in ITemplate and a proper caching api where you can do such things yourself if you need to. We could probably can just make the Run method virtual to support the before and after methods (but I'm not sure when you actually need this)?

@matthid matthid closed this Dec 30, 2014

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment