關閉一些報錯處理的集合


# 請更換npm版本,  # 測試后發現v12.0.0版本出現錯誤,使用v10.x.x版本或者v12.21.x(別的版本沒測試)正常通過
# Fatal error in , line 0  
# Check failed: U_SUCCESS(status).
#
#
#
# FailureMessage Object: 0x7ffeefbfb6b0Illegal instruction: 4 

 # 請降低npm版本

(node:86345) ExperimentalWarning: The fs.promises API is experimental
npm ERR! code ERESOLVE
npm ERR! ERESOLVE unable to resolve dependency tree
npm ERR!
npm ERR! While resolving: vue-antd-ts@0.1.0
npm ERR! Found: vue@3.0.6
npm ERR! node_modules/vue
npm ERR! vue@"^3.0.0" from the root project
npm ERR!
npm ERR! Could not resolve dependency:
npm ERR! peer vue@"^2.6.0" from ant-design-vue@1.7.3
npm ERR! node_modules/ant-design-vue
npm ERR! ant-design-vue@"*" from the root project
npm ERR!
npm ERR! Fix the upstream dependency conflict, or retry
npm ERR! this command with --force, or --legacy-peer-deps
npm ERR! to accept an incorrect (and potentially broken) dependency resolution.
npm ERR!
npm ERR! See /Users/nanguai/.npm/eresolve-report.txt for a full report.


 # Cannot find module 'vue-loader-v16/package.json'

將npm更換為yarn的步驟:

第1步:安裝yarn命令:cnpm install yarn -g

第2步:驗證yarn版本命令:yarn versions

第3步:刪除原node_modules, 重新安裝這里也可以手動刪除node_modules文件夾

第4步:運行命令:yarn run serve(或dev,npm run XXX是執行Vue項目配置在 package.json 中的腳本) 


# Error: PostCSS plugin autoprefixer requires PostCSS 8.

處理:降低autoprefixer版本至@8.0.0


 

# .bezierEasingMixin();
# ^
# Inline JavaScript is not enabled. Is it set in your options?

css: {

  ...
  loaderOptions: {
    less: {
      javascriptEnabled: true
    }
  }
  ...
}


# ant-design-vue按需引入報Antd is not defined 

import Vue from 'vue'

import Antd from 'ant-design-vue/es'

Vue.use(Antd)


 

 

 

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM