ASP.NET Core multiple angular app

前端 未结 3 1591
广开言路
广开言路 2021-02-04 13:42

I have an ASP.NET Core 2.1 and I need to setup workspace for multiple Angular applications with following routing:

http://someurl.com/main -> first app
http://someu

3条回答
  •  难免孤独
    2021-02-04 14:21

    You are registering the Single Page Application (SPA) on the app not the mapped path:

    app.Map("/admin", l =>
    {
        app.UseSpa(spa =>
    

    Change app to l to fix the issue:

    app.Map("/admin", l =>
    {
        l.UseSpa(spa =>
    

提交回复
热议问题