安裝@vue/cli 報(bào)錯npm WARN deprecated request@2.88.2問題
安裝@vue/cli 報(bào)錯npm WARN deprecated request@2.88.2

產(chǎn)生錯誤的原因
是電腦資源的問題,電腦里面沒有配置淘寶鏡像
解決步驟
- 配置淘寶鏡像:
npm config set registry https://registry.npm.taobao.org - 配置完鏡像之后驗(yàn)證是否成功:
npm config get registry
圖示如下:

配置完后問題就解決了!??!
以下附上VueCli的安裝方法
下載VueCli,命令行輸入npm i -g @vue/cli

下載成功,檢查下載的版本vue --version(我下載的是4.2.3版本的)

vue/cli 安裝出錯的解決
安裝vue-cli出錯
D:\code\vue_code>npm install -g @vue/cli
npm ERR! code EINTEGRITY
npm ERR! path C:\Users\xxx\AppData\Local\npm-cache\_cacache\content-v2\sha512\f5\32\605bc70f6f0383c6babf834c59f8b26e5944061f77b86774c8b267c115496e57205801bde1328607527963daab39d70a21084aea54197155e4c264473ecb
npm ERR! errno EINTEGRITY
npm ERR! Invalid response body while trying to fetch https://registry.npm.taobao.org/slash: Integrity verification failed for sha512-9TJgW8cPbwODxrq/g0xZ+LJuWUQGH3e4Z3TIsmfBFUluVyBYAb3hMoYHUnlj2qs51wohCErqVBlxVeTCZEc+yw== (C:\Users\xxx\AppData\Local\npm-cache\_cacache\content-v2\sha512\f5\32\605bc70f6f0383c6babf834c59f8b26e5944061f77b86774c8b267c115496e57205801bde1328607527963daab39d70a21084aea54197155e4c264473ecb)
npm ERR! A complete log of this run can be found in:
npm ERR! C:\Users\xxx\AppData\Local\npm-cache\_logs\2021-12-13T11_46_52_646Z-debug-0.log
解決
清除緩存:
npm cache clear --force
重新安裝:
D:\code\vue_code>npm cache clear --force
npm WARN using --force Recommended protections disabled.
D:\code\vue_code>npm install -g @vue/cli
npm WARN deprecated urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
npm WARN deprecated resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
npm WARN deprecated har-validator@5.1.5: this library is no longer supported
npm WARN deprecated @hapi/bourne@1.3.2: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated graphql-extensions@0.15.0: The `graphql-extensions` API has been removed from Apollo Server 3. Use the plugin API instead: https://www.apollographql.com/docs/apollo-server/integrations/plugins/
npm WARN deprecated apollo-tracing@0.15.0: The `apollo-tracing` package is no longer part of Apollo Server 3. See https://www.apollographql.com/docs/apollo-server/migration/#tracing for details
npm WARN deprecated @hapi/topo@3.1.6: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated apollo-cache-control@0.14.0: The functionality provided by the `apollo-cache-control` package is built in to `apollo-server-core` starting with Apollo Server 3. See https://www.apollographql.com/docs/apollo-server/migration/#cachecontrol for details.
npm WARN deprecated @hapi/address@2.1.4: Moved to 'npm install @sideway/address'
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated uuid@3.4.0: Please upgrade to version 7 or higher. Older versions may use Math.random() in certain circumstances, which is known to be problematic. See https://v8.dev/blog/math-random for details.
npm WARN deprecated request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
npm WARN deprecated @hapi/hoek@8.5.1: This version has been deprecated and is no longer supported or maintained
npm WARN deprecated @hapi/joi@15.1.1: Switch to 'npm install joi'
npm WARN deprecated graphql-tools@4.0.8: This package has been deprecated and now it only exports makeExecutableSchema.\nAnd it will no longer receive updates.\nWe recommend you to migrate to scoped packages such as @graphql-tools/schema, @graphql-tools/utils and etc.\nCheck out https://www.graphql-tools.com to learn what package you should use instead
added 952 packages in 2m
13 packages are looking for funding
run `npm fund` for details
總結(jié)
以上為個人經(jīng)驗(yàn),希望能給大家一個參考,也希望大家多多支持腳本之家。
相關(guān)文章
Vue + element 實(shí)現(xiàn)多選框組并保存已選id集合的示例代碼
這篇文章主要介紹了Vue + element 實(shí)現(xiàn)多選框組并保存已選id集合,本文通過實(shí)例代碼給大家介紹的非常詳細(xì),對大家的學(xué)習(xí)或工作具有一定的參考借鑒價(jià)值,需要的朋友可以參考下2020-06-06
Vue Router去掉url中默認(rèn)的錨點(diǎn)#
vue-router默認(rèn)hash模式——使用URL的hash來模擬一個完整的URL,于是當(dāng)URL改變時,頁面不會重新加載。這篇文章主要介紹了Vue Router去掉url中默認(rèn)的錨點(diǎn)#,需要的朋友可以參考下2018-08-08
Element-ui?Layout布局(Row和Col組件)的實(shí)現(xiàn)
我們在實(shí)際開發(fā)中遇到一些布局的時候會用到Layout布局,本文就詳細(xì)的介紹了Element-ui?Layout布局(Row和Col組件)的實(shí)現(xiàn),具有一定的參考價(jià)值,感興趣的可以了解一下2021-12-12
Vue中?引入使用?babel-polyfill?兼容低版本瀏覽器的方法
最近在項(xiàng)目中使用 webpack 打包后升級,用戶反饋使用瀏覽器(chrome 45)訪問白屏。經(jīng)過排查發(fā)現(xiàn):由于 chrome 45 無法兼容 ES6 語法導(dǎo)致的,接下來給大家介紹下Vue中?引入使用?babel-polyfill?兼容低版本瀏覽器方法,需要的朋友可以參考下2023-02-02
vue3實(shí)現(xiàn)問卷調(diào)查的示例代碼
本文主要介紹了vue3實(shí)現(xiàn)問卷調(diào)查的示例代碼,文中通過示例代碼介紹的非常詳細(xì),對大家的學(xué)習(xí)或者工作具有一定的參考學(xué)習(xí)價(jià)值,需要的朋友們下面隨著小編來一起學(xué)習(xí)學(xué)習(xí)吧2023-05-05
vue component 中引入less文件報(bào)錯 Module build failed
這篇文章主要介紹了vue component 中引入less文件報(bào)錯 Module build failed的解決方法,非常不錯,具有一定的參考借鑒價(jià)值,需要的朋友可以參考下2019-04-04
vue用vis插件如何實(shí)現(xiàn)網(wǎng)絡(luò)拓?fù)鋱D
這篇文章主要介紹了vue用vis插件如何實(shí)現(xiàn)網(wǎng)絡(luò)拓?fù)鋱D,具有很好的參考價(jià)值,希望對大家有所幫助。如有錯誤或未考慮完全的地方,望不吝賜教2022-10-10
elementui源碼學(xué)習(xí)仿寫一個el-tooltip示例
本篇文章記錄仿寫一個el-tooltip組件細(xì)節(jié),從而有助于大家更好理解餓了么ui對應(yīng)組件具體工作細(xì)節(jié),本文是elementui源碼學(xué)習(xí)仿寫系列的又一篇文章,后續(xù)空閑了會不斷更新并仿寫其他組件2023-07-07

