webpack.config.js 790 B

12345678910111213141516171819202122232425262728293031
  1. const webpack = require('webpack');
  2. const path = require('path');
  3. const uglifyPlugin = new webpack.optimize.UglifyJsPlugin();
  4. var bowerComponentsPath = path.join(__dirname, '/bower_components');
  5. module.exports = {
  6. context: __dirname,
  7. entry: './src/js/ionic-material.js',
  8. output: {
  9. libraryTarget: 'umd',
  10. library: 'ionicMaterial',
  11. path: __dirname + '/dist',
  12. filename: 'ionic.material.js',
  13. sourceMapFilename: 'ionic.material.min.js.map'
  14. },
  15. resolve: {
  16. alias: {
  17. waves: path.join(bowerComponentsPath, 'waves/dist/waves.js')
  18. }
  19. },
  20. externals:{
  21. 'angular': 'angular',
  22. 'ionic': 'ionic'
  23. },
  24. plugins: [
  25. // uglifyPlugin
  26. ],
  27. target : 'web',
  28. devtool: 'source-map'
  29. };