項目場景:啟動前端項目時報錯:"digital envelope routines::unsupported"
問題描述
出現(xiàn)這個錯誤是因為 node.js V17版本中最近發(fā)布的OpenSSL3.0,V17后的版本可以嘗試啟用legacy OpenSSL provider來解決這個問題文章來源地址http://www.zghlxwxcb.cn/news/detail-857213.html
解決方案:更改項目中的package.json文件
"scripts": { "dev": "SET NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service serve", "build:prod": "SET NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service build", "start": "SET NODE_OPTIONS=--openssl-legacy-provider && react-scripts start", "build": "SET NODE_OPTIONS=--openssl-legacy-provider && react-scripts build" },
文章來源:http://www.zghlxwxcb.cn/news/detail-857213.html
到了這里,關(guān)于前段項目啟動時遇到錯誤“digital envelope routines::unsupported“的解決辦法的文章就介紹完了。如果您還想了解更多內(nèi)容,請在右上角搜索TOY模板網(wǎng)以前的文章或繼續(xù)瀏覽下面的相關(guān)文章,希望大家以后多多支持TOY模板網(wǎng)!