const path = require("path");
module.exports = {
  lintOnSave: false,
  css: {
    loaderOptions: {
      less: {
        javascriptEnabled: true,
      },
    },
  },
  configureWebpack: {
    // provide the app's title in webpack's name field, so that
    // it can be accessed in index.html to inject the correct title.
    resolve: {
      alias: {
        "@": path.join(__dirname, "src"),
      },
    },
  },
  devServer: {
    proxy: {
      "^/api": {
        target: "http://eccs.run4wd.com/api", //测试
        // target: "http://provider.medilink-global.com.cn/api/",//生产，需api
        ws: true,
        changeOrigin: true,
        pathRewrite: {
          "^/api": "/", // rewrite path
        },
      },
    },
  },
  publicPath: "/",
};
