Skip to content

Commit

Permalink
Merge pull request #7387 from vector-im/matthew/webpack4
Browse files Browse the repository at this point in the history
Webpack4
  • Loading branch information
ara4n authored Sep 27, 2018
2 parents a371bed + c4f6158 commit a38661c
Show file tree
Hide file tree
Showing 5 changed files with 6,110 additions and 1,243 deletions.
10 changes: 7 additions & 3 deletions karma.conf.js
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,12 @@ const olm_entry = webpack_config.entry['olm'];
// 'preprocessors' config below)
delete webpack_config['entry'];

// make sure we're flagged as development to avoid wasting time optimising
webpack_config.mode = 'development';

// add ./test as a search path for js
webpack_config.module.loaders.unshift({
test: /\.js$/, loader: "babel",
webpack_config.module.rules.unshift({
test: /\.js$/, use: "babel-loader",
include: [path.resolve('./src'), path.resolve('./test')],
});

Expand All @@ -46,8 +49,9 @@ webpack_config.module.noParse.push(/sinon\/pkg\/sinon\.js$/);
// ?
webpack_config.resolve.alias['sinon'] = 'sinon/pkg/sinon.js';

webpack_config.resolve.root = [
webpack_config.resolve.modules = [
path.resolve('./test'),
"node_modules"
];

webpack_config.devtool = 'inline-source-map';
Expand Down
Loading

0 comments on commit a38661c

Please sign in to comment.