webpack.prod.config.js 433 B

123456789101112131415161718192021222324
  1. const path = require('path')
  2. module.exports = {
  3. entry: './components/index.js',
  4. output: {
  5. path: path.resolve(__dirname, './'),
  6. filename: '../index.js',
  7. library: 'VueBaiduMap',
  8. libraryTarget: 'umd'
  9. },
  10. module: {
  11. rules: [
  12. {
  13. test: /\.vue$/,
  14. loader: 'vue-loader'
  15. },
  16. {
  17. test: /\.js$/,
  18. loader: 'babel-loader',
  19. exclude: /node_modules/
  20. }
  21. ]
  22. }
  23. }