yarn報錯解決:caniuse-lite is outdated
阿新 • • 發佈:2022-04-22
yarn run v1.22.18
$ vue-cli-service build --mode prod
/ Building for prod...Browserslist: caniuse-lite is outdated. Please run:
npx browserslist@latest --update-db
解決:
yarn add caniuse-lite browserslist yarn add v1.22.18 warning package-lock.json found. Your project contains lock files generated by tools other than Yarn. It is advised not to mix package managers inyarn add caniuse-lite browserslistorder to avoid resolution inconsistencies caused by unsynchronized lock files. To clear this warning, remove package-lock.json. [1/4] Resolving packages... [2/4] Fetching packages... [3/4] Linking dependencies... warning " > [email protected]" has unmet peer dependency "area-data@>=5.0.6". warning" > [email protected]" has unmet peer dependency "css-loader@*". warning " > [email protected]" has unmet peer dependency "webpack@^3.0.0 || ^4.1.0 || ^5.0.0-0". warning " > [email protected]" has unmet peer dependency "webpack@^4.3.0 || ^5.0.0". warning " > [email protected]" has unmet peer dependency "webpack@>=4.0.0 < 6.0.0". warning " > [email protected]" has unmet peer dependency "webpack@^2.0.0 || ^3.0.0 || ^4.0.0". [4/4] Building fresh packages... success Saved lockfile. success Saved 5 new dependencies. info Direct dependencies ├─ browserslist@4.20.2 └─ caniuse-lite@1.0.30001332 info All dependencies ├─ browserslist@4.20.2 ├─ caniuse-lite@1.0.30001332 ├─ escalade@3.1.1 ├─ node-releases@2.0.3 └─ picocolors@1.0.0 Done in 33.54s.