In webforms, I can make my class inherit HtmlContainer and then I can insert HTML into usercontrols of that class. something like this:
<cc:Container1><p>hello world!</p></cc:Container1>
How can I achieve the same functionality in Razor? I mean something like this:
@Html.Gadget(type: Nested){ </p>hello world!</p> }
You’re looking for inline helpers: