背景:
将内网发布到公网
报错
解决方法
代码
文件地点
const { defineConfig } = require('@vue/cli-service')
module.exports = defineConfig({
transpileDependencies: true,
// devServer: {
// allowedHosts: "all"
// }
})
参考链接
https://stackoverflow.com/questions/65643544/how-fix-invalid-host-header-error-in-vue-3-project/71860480#71860480?newreg=7ac87a7fa12341f1a99b1b0bbf8faa7f