You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

133 lines
3.7 KiB

5 years ago
2 years ago
5 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
2 years ago
5 years ago
2 years ago
5 years ago
2 years ago
2 years ago
2 years ago
5 years ago
2 years ago
5 years ago
2 years ago
5 years ago
2 years ago
5 years ago
  1. 'use strict'
  2. // Template version: 1.2.6
  3. // see http://vuejs-templates.github.io/webpack for documentation.
  4. const path = require('path')
  5. module.exports = {
  6. dev: {
  7. // Paths
  8. assetsSubDirectory: '',
  9. assetsPublicPath: '/',
  10. proxyTable: {
  11. '/api/m1/lcode': {
  12. target: 'http://localhost:7014',
  13. changeOrigin: true,
  14. pathRewrite: {
  15. '^/api/m1/lcode': '/'
  16. }
  17. },
  18. '/api/m1/xm': {
  19. target: 'http://localhost:7067',
  20. changeOrigin: true,
  21. pathRewrite: {
  22. '^/api/m1/xm': '/xm'
  23. }
  24. },
  25. /**
  26. '/api/m1/sys': {
  27. target: 'http://localhost:7015',
  28. changeOrigin: true,
  29. pathRewrite: {
  30. '^/api/m1/sys': '/sys'
  31. }
  32. },
  33. **/
  34. // '/api/m1/pay': {
  35. // target: 'http://localhost:7125',
  36. // changeOrigin: true,
  37. // pathRewrite: {
  38. // '^/api/m1/pay': '/pay'
  39. // }
  40. // },
  41. /**
  42. '/api/m1/form': {
  43. target: 'http://localhost:7080',
  44. changeOrigin: true,
  45. pathRewrite: {
  46. '^/api/m1/form': '/form'
  47. }
  48. },
  49. '/api': {
  50. target: 'https://www.qingqinkj.com',
  51. changeOrigin: true,
  52. pathRewrite: {
  53. '^/api': '/api'
  54. }
  55. }
  56. **/
  57. },
  58. // Various Dev Server settings
  59. host: 'localhost', // can be overwritten by process.env.HOST
  60. port: 8015, // can be overwritten by process.env.PORT, if port is in use, a free one will be determined
  61. autoOpenBrowser: true,
  62. errorOverlay: true,
  63. notifyOnErrors: false,
  64. poll: false, // https://webpack.js.org/configuration/dev-server/#devserver-watchoptions-
  65. // Use Eslint Loader?
  66. // If true, your code will be linted during bundling and
  67. // linting errors and warnings will be shown in the console.
  68. useEslint: false,
  69. // If true, eslint errors and warnings will also be shown in the error overlay
  70. // in the browser.
  71. showEslintErrorsInOverlay: false,
  72. /**
  73. * Source Maps
  74. */
  75. // https://webpack.js.org/configuration/devtool/#development
  76. devtool: 'eval',
  77. // If you have problems debugging vue-files in devtools,
  78. // set this to false - it *may* help
  79. // https://vue-loader.vuejs.org/en/options.html#cachebusting
  80. cacheBusting: true,
  81. // CSS Sourcemaps off by default because relative paths are "buggy"
  82. // with this option, according to the CSS-Loader README
  83. // (https://github.com/webpack/css-loader#sourcemaps)
  84. // In our experience, they generally work as expected,
  85. // just be aware of this issue when enabling this option.
  86. cssSourceMap: false,
  87. },
  88. build: {
  89. // Template for index.html
  90. index: path.resolve(__dirname, '../dist/index.html'),
  91. // Paths
  92. assetsRoot: path.resolve(__dirname, '../dist'),
  93. assetsSubDirectory: '',
  94. // you can set by youself according to actual condition
  95. assetsPublicPath: './',
  96. /**
  97. * Source Maps
  98. */
  99. productionSourceMap: false,
  100. // https://webpack.js.org/configuration/devtool/#production
  101. devtool: false,
  102. // Gzip off by default as many popular static hosts such as
  103. // Surge or Netlify already gzip all static assets for you.
  104. // Before setting to `true`, make sure to:
  105. // npm install --save-dev compression-webpack-plugin
  106. productionGzip: false,
  107. productionGzipExtensions: ['js', 'css'],
  108. // Run the build command with an extra argument to
  109. // View the bundle analyzer report after build finishes:
  110. // `npm run build --report`
  111. // Set to `true` or `false` to always turn it on or off
  112. bundleAnalyzerReport: process.env.npm_config_report
  113. }
  114. }