webpack.config.js 947 B

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. 'use strict';
  2. const webpack = require('webpack');
  3. const WebpackNotifierPlugin = require('webpack-notifier');
  4. module.exports = {
  5. entry: __dirname + '/src/entry.js',
  6. devtool: 'eval',
  7. output: {
  8. filename: 'angular-bootstrap-calendar.js'
  9. },
  10. module: {
  11. preLoaders: [{
  12. test: /.*\.js$/,
  13. loaders: ['eslint'],
  14. exclude: /node_modules/
  15. }, {
  16. test: /\.html$/,
  17. loader: 'htmlhint',
  18. exclude: /node_modules/
  19. }],
  20. loaders: [{
  21. test: /\.less$/,
  22. loader: 'style!css!less',
  23. exclude: /node_modules/
  24. }, {
  25. test: /\.html$/,
  26. loader: 'html',
  27. exclude: /node_modules/
  28. }]
  29. },
  30. devServer: {
  31. port: 8000,
  32. inline: true,
  33. hot: true
  34. },
  35. plugins: [
  36. new webpack.IgnorePlugin(/^\.\/locale$/, /moment$/),
  37. new webpack.HotModuleReplacementPlugin(),
  38. new WebpackNotifierPlugin(),
  39. new webpack.DefinePlugin({
  40. EXCLUDE_TEMPLATES: false
  41. })
  42. ]
  43. };