I am trying to create a demo page, and can't solve the next problem, and I tried everything what I found on the web. I have an anchor tag with tag helper:
<a class="menu-link" asp-area="" asp-controller="Telefon" asp-action="Index">Telefonok</a>
I also added a _ViewImports.cshtml and in it I added as I saw in the net @addTagHelper "*, Microsoft.AspNet.Mvc.TagHelpers", but I still got an error: The name 'addTagHelper' does not exist in the current context
What did I wrong?!
There are two _ViewImports.cshtml, you probably need the one located in the Views Folder.
In my project I have a another one under Views/Manage
Also the line required should be as follows:
@addTagHelper *, Microsoft.AspNetCore.Mvc.TagHelpers
This I believe means it will include all of the Tag Helpers in the namespace.
Note the use of the Asterix (*)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With