ASP.NET Core application won't run: no DIST folder and "Cannot find module './wwwroot/dist/vendor-manifest.json'"
My problem solved by running these commands :
node node_modules/webpack/bin/webpack.js --config webpack.config.vendor.js
node node_modules/webpack/bin/webpack.js
This was probably a caching problem, based on I just installed Node.js
+NPM
and Webpack
.
What I did was the following:
- Made sure to restart my computer
- Verify that all dependencies was good: Node.js+NPM installed, Node in PATH, Webpack installed globally
- Clean everything in my solution
- Rebuild in Visual Studio
It suddenly started working in my end after a couple of times, so pretty sure it's some local cache that caused the problem from not having the dependencies in order.
Another trick I tried was to pull an earlier version of the application from my repo, which seemed to "refresh" the cache (or whatever was the problem). After going back to an earlier version and then back to the newest, things just worked.