I’m just learning how to do ASP MVC. All of the tutorials I see use a combination of Html.LabelFor and the DisplayAttribute. Personally, I’m not a big fan of adding these kinds of annotations to my model objects and I’d like to know if there is an accepted alternative. I thought this might be a place for something like Knockout or Backbone, but I’m so new to this stuff that I’m having difficulty wrapping my brain around the different pieces.
I know this has probably already been asked and answered; I can’t even figure out how to google it 🙁
Thanks in advance
you can skip Data Annotations
you can write
or
or
or
any of this will be correct
also using helpers with lamda expressions (Html.LabelFor) is much slower than Html.Label or simple html code
<label for='@(var1)'>@Name</label>It is true for all asp.net mvc html helpers