我使用 Vue cli 创建了这个应用程序。babel.config.js 已经在 cli 自动创建的目录中,但我添加了 vue.config.js 文件。这两个文件有什么区别,我可以合并它们吗?这令人困惑,因为它们都以“config.js”结尾,所以我认为它们可能有一些共同点。
这是我的 babel.config.js
module.exports = {
presets: [
'@vue/cli-plugin-babel/preset'
]
}
Run Code Online (Sandbox Code Playgroud)
这是我的 vue.config.js
module.exports = {
devServer: {
proxy: {
'^/users': {
target: 'http://localhost:5000',
ws: true,
changeOrigin: true
},
'^/api': {
target: 'http://localhost:5000',
ws: true,
changeOrigin: true
}
}
}
};
Run Code Online (Sandbox Code Playgroud)