vue.config.js 780 B

12345678910111213141516171819202122232425262728293031323334
  1. const CopyWebpackPlugin = require('copy-webpack-plugin');
  2. module.exports = {
  3. css: {
  4. loaderOptions: {
  5. css: {},
  6. postcss: {
  7. plugins: [
  8. require('postcss-px2rem')({
  9. remUnit: 192
  10. })
  11. ]
  12. }
  13. }
  14. },
  15. devServer: {
  16. proxy: {
  17. '/api': {
  18. target: 'http://dnzk.baianxi.com/',
  19. changeOrigin: true,
  20. }
  21. }
  22. },
  23. publicPath: '',
  24. configureWebpack: {
  25. plugins: [
  26. new CopyWebpackPlugin([
  27. { from: 'node_modules/@liveqing/liveplayer/dist/component/crossdomain.xml'},
  28. { from: 'node_modules/@liveqing/liveplayer/dist/component/liveplayer.swf'},
  29. { from: 'node_modules/@liveqing/liveplayer/dist/component/liveplayer-lib.min.js',to: 'js/'},
  30. ])
  31. ]
  32. }
  33. }