我注意到在节点 15 和 npm 7 上,当我从节点 14 切换时,同一包有重复的条目。一是apollo-server-core哪个都好。另一个是node_modules/apollo-server-core我在使用 npm 7 运行时添加的。另请注意,对于我拥有的每个依赖项,都会创建npm install另一个带有前缀的条目。node_modules/这是 npm 7 特意添加的还是一个错误?
例如:
使用 npm 7 时创建
"node_modules/apollo-server-core": {
"version": "2.19.0",
"resolved": "https://registry.npmjs.org/apollo-server-core/-/apollo-server-core-2.19.0.tgz",
"integrity": "sha512-2aMKUVPyNbomJQaG2tkpfqvp1Tfgxgkdr7nX5zHudYNSzsPrHw+CcYlCbIVFFI/mTZsjoK9czNq1qerFRxZbJw==",
"dependencies": {
"@apollographql/apollo-tools": "^0.4.3",
"@apollographql/graphql-playground-html": "1.6.26",
"@types/graphql-upload": "^8.0.0",
"@types/ws": "^7.0.0",
"apollo-cache-control": "^0.11.4",
"apollo-datasource": "^0.7.2",
"apollo-graphql": "^0.6.0",
"apollo-reporting-protobuf": "^0.6.1",
"apollo-server-caching": "^0.5.2",
"apollo-server-env": "^2.4.5",
"apollo-server-errors": "^2.4.2",
"apollo-server-plugin-base": "^0.10.2",
"apollo-server-types": "^0.6.1",
"apollo-tracing": "^0.12.0",
"async-retry": "^1.2.1",
"fast-json-stable-stringify": "^2.0.0",
"graphql-extensions": "^0.12.6",
"graphql-tag": "^2.9.2",
"graphql-tools": "^4.0.0",
"graphql-upload": "^8.0.2",
"loglevel": "^1.6.7", …Run Code Online (Sandbox Code Playgroud)