Nie możesz wybrać więcej, niż 25 tematów Tematy muszą się zaczynać od litery lub cyfry, mogą zawierać myślniki ('-') i mogą mieć do 35 znaków.

4 lat temu
4 lat temu
4 lat temu
4 lat temu
4 lat temu
123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263
  1. const path = require('path');
  2. const webpack = require('webpack');
  3. module.exports = {
  4. configureWebpack: {
  5. resolve: {
  6. alias: {
  7. '@': path.join(__dirname, 'src'),
  8. }
  9. },
  10. // externals: {
  11. // back: 'back',
  12. // jquery: 'jQuery',
  13. // $: 'jQuery',
  14. // WebUploader: 'WebUploader',
  15. // },
  16. externals: {
  17. jquery: 'window.$',
  18. $: 'window.$'
  19. },
  20. plugins: [
  21. new webpack.DefinePlugin({
  22. 'process.env': {
  23. NODE_ENV: '"development"',
  24. API_HOST: '"/api/"',
  25. // API_HOST: '"http://47.104.91.134:9000/api/"',
  26. }
  27. }),
  28. ],
  29. devServer: {
  30. proxy: {
  31. '/api/pms': {
  32. target: 'http://47.104.91.134:8089',
  33. // target:'http://10.240.32.217:8089',
  34. changeOrigin: true,
  35. secure: false,
  36. },
  37. '/api': {
  38. target: 'http://47.104.91.134:8080',
  39. // target: 'http://10.240.32.245:8080',
  40. changeOrigin: true,
  41. secure: false,
  42. }
  43. },
  44. },
  45. },
  46. css: {
  47. loaderOptions: {
  48. sass: {
  49. // 根据自己样式文件的位置调整
  50. additionalData: `@import "@/global.variable.scss";`
  51. }
  52. }
  53. },
  54. assetsDir: 'static',
  55. // configureWebpack: config => {
  56. // console.log('????')
  57. // return config;
  58. // }
  59. }