vue_admin icon indicating copy to clipboard operation
vue_admin copied to clipboard

npm 运行vue项目时,报错:Error: error:0308010C:digital envelope routines::unsupported

Open pl1998 opened this issue 2 years ago • 0 comments

主要是nodeJs V17版本发布了OpenSSL3.0对算法和秘钥大小增加了更为严格的限制,导致了nodeJs V17之前版本不受影刺而nodeJs V17和之后的版本会出现这个错误。 在 scripts 设置 set NODE_OPTIONS=--openssl-legacy-provider

"scripts": {
    "dev": "set NODE_OPTIONS=--openssl-legacy-provider & vue-cli-service serve",
    "lint": "eslint --ext .js,.vue src",
    "build:prod": "vue-cli-service build",
    "build:stage": "vue-cli-service build --mode staging",
    "preview": "node build/index.js --preview",
    "new": "plop",
    "svgo": "svgo -f src/icons/svg --config=src/icons/svgo.yml",
    "test:unit": "jest --clearCache && vue-cli-service test:unit",
    "test:ci": "npm run lint && npm run test:unit"
  },

pl1998 avatar Oct 13 '23 03:10 pl1998