步骤一: 将config/index.js 中的host: localhost 改为 host:'0.0.0.0'步骤二:在package.json 将scripts 下面的dev 后面添加 --host 0.0.0.0
截图如下