I'm currently working on implementing server side rendering for an application using react-redux and express for the server. We are also utilizing webpack to bundle our assets.
To get started, I referred to the following documentation:
https://redux.js.org/docs/recipes/ServerRendering.html
Here is how I have set up loading the main.js file generated by webpack:
<script type="application/javascript" src="/static/main.js"></script>
However, when I run the express server, I encounter the following error in the console:
Refused to execute script from 'http://localhost:8080/static/main.js' because its MIME type ('text/html') is not executable, and strict MIME type checking is enabled.
This issue is preventing the app from running in any browser. Any insights on what might be causing this problem?