Reputation: 736
All of a sudden I'm getting this error for practically all modules installed.
Sourcemap for "C:/.../node_modules/.vite/react.js" points to missing source files Sourcemap for "C:/.../node_modules/.vite/axios.js" points to missing source files Sourcemap for "C:/.../node_modules/.vite/react-dom.js" points to missing source files Sourcemap for "C:/.../node_modules/.vite//react_jsx-dev-runtime.js" points to missing source files
package.json:
{
"name": "ic-logistic",
"version": "0.0.0",
"proxy": "http://localhost:8080/",
"private": true,
"scripts": {
"dev": "vite",
"build": "vite build",
"serve": "vite preview"
},
"dependencies": {
"axios": "^0.24.0",
"dotenv": "^10.0.0",
"mapbox-gl": "^2.5.0",
"react": "^17.0.0",
"react-dom": "^17.0.0",
"react-map-gl": "^6.1.17",
"react-redux": "^7.2.5",
"react-router-dom": "^5.3.0",
"redux": "^4.1.1",
"redux-devtools-extension": "^2.13.9",
"sass": "^1.42.1"
},
"devDependencies": {
"@vitejs/plugin-react": "^1.0.0",
"vite": "^2.6.0"
}
}
Upvotes: 8
Views: 21762
Reputation: 1631
Extending @nefaris answer, what solved it for me was replacing v1.0.x with 1.0.8 :
npm install @vitejs/[email protected] --save-dev
Upvotes: 2
Reputation: 130
Just change @vitejs/plugin-react
version from "^1.0.0"
to exact version "1.0.5"
. You can read more about this error in this thread: https://github.com/vitejs/vite/issues/5438
Upvotes: 5