Hello, I ran into an issue when running dotnet publish:
I am using angular 4.2.5
Also checked with angular 4.4.3 - same issue.
Please let me know what's seems to be the problem.
Thank you.

Probably a server side rendering setup issue like angular-cli https://github.com/angular/angular-cli/issues/7200
As part of publishing, ensure the JS resources are freshly built in production mode:
Right-click and edit the .csproj file - this command causing the issue:
node node_modules/webpack/bin/webpack.js --env.prod
I've confirmed the issue. I'm not a webpack expert so only assuming I added this package correctly to the webpack.config.vendor.js file. I don't know what causes this. angular-cli uses webpack internally but somehow both are treating this library differently.
@sollygit Does this help? https://github.com/aspnet/JavaScriptServices/issues/1293
Yes, thank you guys !
I had to remove include: /ClientApp/ from my webpack.config.js and it worked.
Glad to hear. No problem.
I have this issue but with ngx-bootstrap and i do not have the line "incude: /ClientApp/" in my webpack.config.js file
Most helpful comment
Yes, thank you guys !
I had to remove include: /ClientApp/ from my webpack.config.js and it worked.
https://github.com/aspnet/JavaScriptServices/issues/1168