开发者

What are few advantages of Razor view engine over other view engines

开发者 https://www.devze.com 2023-02-05 01:24 出处:网络
I want to know what are few advantages of Razor view engine other then its syntax over other view engines like Spark, NHaml or default aspx v开发者_如何学运维iew engine. Also what is the performance d

I want to know what are few advantages of Razor view engine other then its syntax over other view engines like Spark, NHaml or default aspx v开发者_如何学运维iew engine. Also what is the performance difference between them


For some performance numbers see my blog post:

http://blogs.msdn.com/b/marcinon/archive/2011/01/17/mvc-3-performance.aspx

Razor is nominally a bit slower than aspx but in a real world application (that does database access etc) this would not be a big deal (unless you are running a really big site where you need to squeeze every bit of performance).


This blogpost by Haack should get you a long way. Also there is a link in the article for the basics.

http://haacked.com/archive/2011/01/06/razor-syntax-quick-reference.aspx


Does not require you to explicitly close the code-block, this view engine is parsed intelligently by the run-time to determine what is a presentation element and what is a code element.

0

精彩评论

暂无评论...
验证码 换一张
取 消