1. 安装nodejs
dnf -y install nodejs
npm config set registry https://registry.npm.taobao.org -g
npm config get registry https://registry.npm.taobao.org/
2. 安装n
npm install n -g
npm cache verify
n 10
n # 选择版本10
dnf -y install nodejs
npm config set registry https://registry.npm.taobao.org -g
npm config get registry https://registry.npm.taobao.org/
npm install n -g
npm cache verify
n 10
n # 选择版本10