This repository was archived by the owner on Apr 8, 2020. It is now read-only.
This repository was archived by the owner on Apr 8, 2020. It is now read-only.
Using @addTagHelper in ASP.NET Core WebAPI #1002
Closed
Description
I am following this tutorial of "Microsoft.AspNetCore.SpaServices Server Side Prerendering" and there are two important steps to use power "Microsoft.AspNetCore.SpaServices":
1. Go to your "Views/_ViewImports.cshtml" file, and add the following line:
@addTagHelper "*,
Microsoft.AspNetCore.SpaServices"`
2. Choose a place in one of your MVC views where you `want to prerender a SPA component. For example, open "Views/Home/Index.cshtml", and add markup like the following:
<div id="my-spa" asp-prerender-module="ClientApp/boot-server"></div>
But "Web Api" does not have "Views" folder. How can I do above steps in Web API?
Metadata
Metadata
Assignees
Labels
No labels