This project is read-only.

RazorEngine.Razor.Parse cached


I am using a foreach statement to parse a number of templates. So I have to parse a number of templates using the same model.

The first parse returns the correct html however all remaining parsers continue to return the first html aswell, almost as if it is cached.

Simple example code:
 string html = string.empty; 
 List<string> templates = GetListOfTemplates(); 

 foreach(var t in templates) 
        html = RazorEngine.razor.Parse(t, model, "myRazor");
        //Do Something with 'html'


nZeus wrote Oct 20, 2014 at 8:56 AM

We have the same issue. Compile doesn't work as well