const path = require('path');
module.exports = {
configureWebpack: {
resolve: {
alias: {
'@': path.resolve(__dirname, 'src'),
style: path.resolve(__dirname, 'src/style')
}
}
},
devServer: {
port: 8081,
proxy: {
'/api': {
target: 'http://localhost:8081',
changeOrigin: true,
pathRewrite: {
'^/api': '/mock'
}
}
}
},
css: {
loaderOptions: {
sass: {
prependData: '@import "~@/style/variable.scss";'
}
}
}
};
vue-cli3.0 vue.config.js常用配置
最新推荐文章于 2022-12-08 22:41:13 发布