官方文档地址:
https://pro.ant.design/docs/getting-started
首先安装nodejs
然后根据官方文档走
npm i @ant-design/pro-cli -g
pro create myapp
然后选择
umi@3
选择
simple
然后cd myapp
npm install
npm start
然后出错
ant design pro this[kHandle] = new _Hash(algorithm, xofLen);
这一行解决办法
修改package.json这两行
"start": "set NODE_OPTIONS=--openssl-legacy-provider && cross-env UMI_ENV=dev umi dev",
"dev": "set NODE_OPTIONS=--openssl-legacy-provider && npm run start:dev",
详细原因可参考:
umi项目启动报错node:internal/crypto/hash:71this[kHandle] = new _Hash(algorithm, xofLen);_今夜來看雪的博客-CSDN博客
解决后会出现
in ./src/components/index.md
Module build failed (from ./node_modules/@umijs/preset-dumi/lib/loader/index.js):
解决办法可参照