Failed to load module script: Expected a JavaScript module script #16746
Unanswered
simplepry-s
asked this question in
Q&A
Replies: 1 comment 1 reply
-
I have the problem too. |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Describe the bug
i got error
Failed to load module script: Expected a JavaScript module script but the server responded with a MIME type of "text/html". Strict MIME type
when i have new release version (deployment) but when i reload the web page the issue is gone
i try this solution but it now working
https://vitejs.dev/guide/build.html#load-error-handling
here my vite config
export default defineConfig({
plugins: [react()],
base: './',
server: {
port: 3000,
}
resolve: {
alias: {
components: resolve(dirname, 'src/components')
},
},
});
Reproduction
Steps to reproduce
System Info
Used Package Manager
npm
Logs
No response
Validations
Beta Was this translation helpful? Give feedback.
All reactions