I\'m trying to add additional attribute data-icon to my Action Link, but I\'m getting the error below:
Invalid anonymous type member
Use "data_icon" instead of "data-icon".
@Html.ActionLink("Profile", "Details", "Profile", new { id = 11 }, new { @rel = "external", @id = "btnProfile", @data_icon = "gear" })
The _ will automatically be converted to - in the resulting markup.