I noticed something weird in my MVC project. I actually went back to the vanilla version to try it out and found out that the following (last list item being my only addition to the project, except for the action Test in the controller, only returning an empty instance of View) works well.
<ul class="nav navbar-nav">
<li>@Html.ActionLink("Home", "Index", "Home")</li>
<li>@Html.ActionLink("About", "About", "Home")</li>
<li>@Html.ActionLink("Contact", "Contact", "Home")</li>
<li>@Html.ActionLink("Test", "Test", "Home")</li>
</ul>
However, when I added style to the action link as follows, I get an error. It works still but now VS remarks and when I check the remark, it asks me if I want to create a new controller Shared and an action Test.
<ul class="nav navbar-nav">
<li>@Html.ActionLink("Home", "Index", "Home")</li>
<li>@Html.ActionLink("About", "About", "Home")</li>
<li>@Html.ActionLink("Contact", "Contact", "Home")</li>
<li>@Html.ActionLink("Test", "Test", "Home", new { @style = "color: blue;" })</li>
</ul>
Why is it so? Is it a real problem at all?