webpack.test.js 572 B

1234567891011121314151617181920212223
  1. const webpack = require('webpack');
  2. const merge = require('webpack-merge');
  3. const common = require('./webpack.common.js');
  4. config = merge(common, {
  5. devtool: 'inline-source-map',
  6. externals: {
  7. 'react/addons': true,
  8. 'react/lib/ExecutionEnvironment': true,
  9. 'react/lib/ReactContext': true,
  10. },
  11. node: {
  12. fs: 'empty'
  13. },
  14. plugins: [
  15. new webpack.SourceMapDevToolPlugin({
  16. filename: null, // if no value is provided the sourcemap is inlined
  17. test: /\.(ts|js)($|\?)/i // process .js and .ts files only
  18. })
  19. ]
  20. });
  21. module.exports = config;