💎一站式轻松地调用各大LLM模型接口,支持GPT4、智谱、星火、月之暗面及文生图 广告
1、webpack.dev.conf.js ``` module.exports\=newPromise((resolve, reject) \=> {   portfinder.basePort\=process.env.PORT || config.dev.port   portfinder.getPort((err, port) \=> { if (err) { reject(err)     } else { // publish the new Port, necessary for e2e tests process.env.PORT \=port // add port to devServer config devWebpackConfig.devServer.port \=port // Add FriendlyErrorsPlugin devWebpackConfig.plugins.push(newFriendlyErrorsPlugin({ compilationSuccessInfo: { // messages: \[`Your application is running here: http://${devWebpackConfig.devServer.host}:${port}`\], //}, messages: \[ `App runing at: `, `Local: http://localhost:${port}`, `Network: http://${require('ip').address()}:${port}`,         \],       }, onErrors: config.dev.notifyOnErrors ? utils.createNotifierCallback() :undefined       })) resolve(devWebpackConfig)     }   }) }) ``` 2、config/index.js ``` dev: { // Paths assetsSubDirectory: 'static', assetsPublicPath: '/', proxyTable: {}, // Various Dev Server settings host: '0.0.0.0', // can be overwritten by process.env.HOST主要是把这里修改成0.0.0.0 ```