There is a way to modify the html created by MVC Helper, but this is not very convenient. In general, you can write this command:
@( new HtmlString( Component.HelperMethod().ToHtmlString().Replace("[replacetag]", "My Content")) )
Here is an example of using a grid component:
<div id="grid"> @(new HtmlString( grid.GetHtml( tableStyle: "grid", headerStyle: "header", rowStyle: "row", footerStyle: "footer", alternatingRowStyle: "altRow", columns: grid.Columns( grid.Column("Name", "[replacethis]"), grid.Column("Surname", "Surname"), grid.Column("Email", "Sender Email"), grid.Column("Id", "", format: (item) => item.GetSelectLink("Select"), canSort: false)) ).ToHtmlString().Replace("[replacethis]", "<b>Name</b>") ) ) </div>
source share