123456789101112131415161718192021222324252627282930313233343536373839404142
  1. module.exports = {
  2. env: {
  3. NODE_ENV: '"production"'
  4. },
  5. defineConstants: {
  6. // HOST: '"http://192.168.89.25:9087"',
  7. HOST: '"https://wmcj.huoshannews.com"',
  8. AD_IMAGE: '"https://h5.njyunzhi.com/images/citizen_banner.png"',
  9. DEFAULT_POS: '"116.3476917447715,31.409912844296578"', // 霍山县人民政府 gcj02
  10. VERSION: '"1.1.22-20230413"',
  11. },
  12. mini: {},
  13. h5: {
  14. /**
  15. * WebpackChain 插件配置
  16. * @docs https://github.com/neutrinojs/webpack-chain
  17. */
  18. // webpackChain (chain) {
  19. // /**
  20. // * 如果 h5 端编译后体积过大,可以使用 webpack-bundle-analyzer 插件对打包体积进行分析。
  21. // * @docs https://github.com/webpack-contrib/webpack-bundle-analyzer
  22. // */
  23. // chain.plugin('analyzer')
  24. // .use(require('webpack-bundle-analyzer').BundleAnalyzerPlugin, [])
  25. // /**
  26. // * 如果 h5 端首屏加载时间过长,可以使用 prerender-spa-plugin 插件预加载首页。
  27. // * @docs https://github.com/chrisvfritz/prerender-spa-plugin
  28. // */
  29. // const path = require('path')
  30. // const Prerender = require('prerender-spa-plugin')
  31. // const staticDir = path.join(__dirname, '..', 'dist')
  32. // chain
  33. // .plugin('prerender')
  34. // .use(new Prerender({
  35. // staticDir,
  36. // routes: [ '/pages/index/index' ],
  37. // postProcess: (context) => ({ ...context, outputPath: path.join(staticDir, 'index.html') })
  38. // }))
  39. // }
  40. }
  41. }