using Meleze.web with razor generator

Feb 2, 2012 at 2:33 PM

When i use razor generator i can't optimize my views with meleze.web it just no work, looks like if never been invoked.

Any idea? i have google a lot without any result.

Feb 2, 2012 at 7:17 PM

I have not used meleze.web, so I'm not sure. Can you provide more details about what the issue is? What does meleze.web do, and what's not working?

And note that RazorGenerator is not about optimizing views, but about generating the source at design time so it can be compiled in a regular assembly.

Feb 2, 2012 at 8:16 PM
Edited Feb 2, 2012 at 8:33 PM

Meleze.Web is a tool that overrides VisitSpan method of the MvcCSharpRazorCodeGenerator Class to apply algorithm that performs minification to remove the whitespace of the HTML before Razor generates DLL.
I am trying to perform this minification with Meleze before the RazorGenerator invokes and compiles the view.
Thanks in advance!

Feb 3, 2012 at 1:42 AM

I see. Well, with RazorGenerator, we invoke the generator at design time and not runtime. So you would somehow need to hook in that logic at that time. You may want to look through the RazorGenerator to see where it's all happening, which maybe will lead to possible solutions.