我认为我正在使用适当的node/npm/node-sass版本,但仍然在运行npm start命令时出现错误 - " Node Sass version 7.0.1 is incompatible with ^4.0.0"。 我不确定这个4.0.0版本是什么。 它没有在下面任何一个给定的版本中。
已安装版本如下
Node version - 16.15.0
NPM version - 8.11.0
Node Sass version - 7.0.1
以下是 package.json 文件
{
"name": "test-app",
"version": "0.1.0",
"private": true,
"dependencies": {
"@testing-library/jest-dom": "^4.2.4",
"@testing-library/react": "^9.3.2",
"@testing-library/user-event": "^7.1.2",
"http-proxy-middleware": "^1.0.6",
"node-sass": "^7.0.1",
"normalize-scss": "^7.0.1",
"react": "^16.13.1",
"react-dom": "^16.13.1",
"react-router-dom": "^5.2.0",
"react-scripts": "^2.1.3"
},
"scripts": {
"start": "react-scripts start",
"build": "react-scripts build",
"test": "react-scripts test",
"eject": "react-scripts eject"
},
"eslintConfig": {
"extends": "react-app"
},
"browserslist": {
"production": [
">0.2%",
"not dead",
"not op_mini all"
],
"development": [
"last 1 chrome version",
"last 1 firefox version",
"last 1 safari version"
]
},
"devDependencies": {
"sass": "^1.52.1"
}
}
有人能猜到是什么导致了不兼容的问题吗?