关闭一些报错处理的集合

# 请更换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)


 

黄昏时拿你的肋骨酿酒,百年后醉的有血有肉。
原文地址:https://www.cnblogs.com/wanan-happy/p/14446927.html