-
-
-
-
+
\ No newline at end of file
+
diff --git a/vue.config.js b/vue.config.js
index 66b90e0..1905abc 100644
--- a/vue.config.js
+++ b/vue.config.js
@@ -1,32 +1,32 @@
-const { defineConfig } = require('@vue/cli-service')
+const { defineConfig } = require("@vue/cli-service");
const path = require("path");
module.exports = defineConfig({
- publicPath: '/',
- assetsDir: 'static',
+ publicPath: "/",
+ assetsDir: "static",
transpileDependencies: true,
- lintOnSave:false,
+ lintOnSave: false,
pluginOptions: {
- 'style-resources-loader': {
- preProcessor: 'less',
+ "style-resources-loader": {
+ preProcessor: "less",
patterns: [
// 这个是加上自己的路径
- path.resolve(__dirname, './src/assets/css/global.less')
- ]
- }
+ path.resolve(__dirname, "./src/assets/css/global.less"),
+ ],
+ },
},
devServer: {
proxy: {
- '/api': {//表示拦截以/api开头的请求路径
- //target: 'http://localhost:1234', //本地nodejs服务器
- //target: 'http://47.96.238.157:8093', //公司项目服务器环境
- target: 'http://180.166.218.222:7200',
- changOrigin: true,//是否开启跨域
- pathRewrite: {
- '^/api': '' //重写api,把api变成空字符,因为我们真正请求的路径是没有api的
- }
- }
- }
-
-}
-})
+ "/api": {
+ //表示拦截以/api开头的请求路径
+ //target: 'http://localhost:1234', //本地nodejs服务器
+ target: "http://47.96.238.157:8093", //公司项目服务器环境
+ //target: 'http://180.166.218.222:7200',
+ changOrigin: true, //是否开启跨域
+ pathRewrite: {
+ "^/api": "", //重写api,把api变成空字符,因为我们真正请求的路径是没有api的
+ },
+ },
+ },
+ },
+});