1

我尝试将我的 angular2 应用程序更改为 angular2 通用。在那我隔离了服务器和客户端模块。在执行 npm start 时,我收到以下错误。

EXCEPTION: The selector "app-root" did not match any elements
ORIGINAL STACKTRACE:
Error: The selector "app-root" did not match any elements
    at DomRenderer.selectRootElement (C:\Users\SYS168\scotchiversal - Copy\dist\server\index.js:26663:23)
    at selectOrCreateRenderHostElement (C:\Users\SYS168\scotchiversal - Copy\dist\server\index.js:15131:32)
    at AppView._View_AppComponent_Host0.createInternal (/AppModule/AppComponent/host.ngfactory.js:12:16)
    at AppView.create (C:\Users\SYS168\scotchiversal - Copy\dist\server\index.js:51125:21)
    at ComponentFactory.create (C:\Users\SYS168\scotchiversal - Copy\dist\server\index.js:36104:36)
    at ApplicationRef_.bootstrap (C:\Users\SYS168\scotchiversal - Copy\dist\server\index.js:22794:40)
    at C:\Users\SYS168\scotchiversal - Copy\dist\server\index.js:22703:89
    at Array.forEach (native)
    at PlatformRef_._moduleDoBootstrap (C:\Users\SYS168\scotchiversal - Copy\dist\server\index.js:22703:42)
    at C:\Users\SYS168\scotchiversal - Copy\dist\server\index.js:22671:27

你能请人帮帮我吗?这是我的文件夹结构https://s11.postimg.org/g5xht8k6b/git.png

我的文件夹结构

4

0 回答 0