123456789101112131415161718192021222324252627282930313233343536373839 |
- const defProxy = {
- "/api": {
- target: process.env.VUE_APP_MAIN_PROXY,
- changeOrigin: true,
- },
- "/file": {
- target: process.env.VUE_APP_MAIN_PROXY_FILE,
- changeOrigin: true,
- },
- };
- var webpack = require("webpack");
- module.exports = {
- lintOnSave: process.env.NODE_ENV !== "production" ? true : "error",
- devServer: {
- proxy: defProxy,
- },
- pages: {
- index: {
- entry: "src/main.js",
- template: "public/index.html",
- filename: "index.html",
- },
- download: {
- entry: "pages/download/main.js",
- template: "public/download.html",
- filename: "download.html",
- },
- },
- configureWebpack: {
- devtool: "source-map",
- plugins: [
- // Ignore all locale files of moment.js
- // TODO: use webpack stats to check if iview locale matters
- new webpack.IgnorePlugin(/^\.\/locale$/, /moment|iview$/),
- ],
- },
- transpileDependencies: [/\bvue-awesome\b/],
- };
|