maoberlehner / distributed-vue-applications-loading-components-via-http

This is an example project for the following article: https://markus.oberlehner.net/blog/distributed-vue-applications-loading-components-via-http/
49 stars 14 forks source link

'Cannot get' message on node server #3

Open sebasijan opened 4 years ago

sebasijan commented 4 years ago

After following the steps in the readme, I can see that both client and server applications are running, but when navigating to localhost:8080, I only see this:

image

With these errors in the console:

The resource from “http://localhost:8200/MyComponent/MyComponent.c9c0abb8e999d0e5654e.umd.min.js” was blocked due to MIME type (“text/html”) mismatch (X-Content-Type-Options: nosniff).

[Vue warn]: Failed to resolve async component: function MyComponent() { return Object(_utils_external_component__WEBPACK_IMPORTED_MODULE_0__["default"])("http://localhost:8200/MyComponent/MyComponent.c9c0abb8e999d0e5654e.umd.min.js"); } Reason: Error: Error loading http://localhost:8200/MyComponent/MyComponent.c9c0abb8e999d0e5654e.umd.min.js

I can see that this file exists (I had to run the npx command from the article to create it) and when navigating to localhost:8200 itself I get this message:

Cannot GET /

Any idea why this might happen?