News for hackers. Stuff that matters.
Re:Razor Syntax in ASP.NET MVC 3 Preview 1 by Daishiman on Saturday September 04, 2010 @01:16PM (#1663003)
Ruby and Python templating engines are better.
Re:Razor Syntax in ASP.NET MVC 3 Preview 1 by some1else on Saturday September 04, 2010 @03:42PM (#1663260)
Haml/Sass is the best thing that happened to my view layer (next to wonderful Ruby blocks, iterators and chaining)
Re:Razor Syntax in ASP.NET MVC 3 Preview 1 by epochwolf on Saturday September 04, 2010 @04:47PM (#1663363)
Look up NHaml.
Re:Razor Syntax in ASP.NET MVC 3 Preview 1 by kennedywm on Saturday September 04, 2010 @04:40PM (#1663354)
How so? I haven't used them and I wouldn't mind reading a comparison.
Re:Razor Syntax in ASP.NET MVC 3 Preview 1 by Daishiman on Saturday September 04, 2010 @06:11PM (#1663508)
The driving philosophy of these engines is that your presentation layer should not contain any logic that goes beyond the rendering of data, and your templating should be an aid to outputting HTML, not merely a medium.

Take Django templates, for example: you output data using tags and filters, with support for defining commonly-used blocks of HTML to reduce redundancy. Take Haml, which uses CSS selector syntax to reduce the amount of HTML boileplate to a bare minimum.

The common factor of these engines is that your end up writing less code than plain HTML, and unlike this new engine for ASP, the mixing of code and presentation doesn't look completely horrendous.