All Html helpers are c# extension methods that are used to generate Html type of string. then why did they not called function/Method instead of Helpers?
Loading
All Html helpers are c# extension methods that are used to generate Html type of string. then why did they not called function/Method instead of Helpers?
html helpers are nothing but controls as we use in asp. net MVc. net we call it as helpers
Because they all generate Html type of element which returns type is “MvcHtmlString” and It is a type of “HtmlHelper” class. All the Html c# extension methods are inside the “HtmlHelper” class. And the people remember them easily.
Example:
public static MvcHtmlString TextBox(this HtmlHelper htmlHelper, string name);
More detail:
Html Helpers are C# methods then why did they call them helpers