简体   繁体   中英

When creating a Blazor application, in what cases would I select "ASP.NET Core hosted"?

Here's the prompt that I see in Visual Studio:

在此处输入图片说明

In what cases should I check the box that says "ASP.NET Core hosted"?

I would like to follow the client-side model here (no SignalR), and my intent is to right-click-publish to an Azure App Service.

... to right-click-publish to an Azure App Service.

Means you want to use a service (providing an API backend).

In that case the "Hosted" template is the ideal starter kit. It essentially is two projects in one: an independent SPA application and an API Service.

But do note that you could develop those two independently as well.

When you don't need/want a service then simply don't check the "Hosted" option. And then there is no need for an App service to deploy to.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM