Re-enable strict CJS interop
[incubator-annotator.git] / webpack.config.js
1 /**
2 * @license
3 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
4 * use this file except in compliance with the License. You may obtain a copy of
5 * the License at
6 *
7 * http://www.apache.org/licenses/LICENSE-2.0
8 *
9 * Unless required by applicable law or agreed to in writing, software
10 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
11 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
12 * License for the specific language governing permissions and limitations under
13 * the License.
14 */
15
16 /* eslint-env node */
17 /* eslint-disable import/unambiguous */
18
19 const path = require('path');
20
21 module.exports = {
22 context: path.resolve(__dirname),
23 entry: {
24 demo: './demo/index.js',
25 test: [
26 'chai/register-assert',
27 'mocha-loader!multi-entry-loader?include=./packages/*/test/**/*.mjs!',
28 ],
29 },
30 devtool: 'inline-source-map',
31 mode: 'development',
32 module: {
33 rules: [
34 {
35 test: /\.m?js$/,
36 exclude: /node_modules/,
37 use: 'babel-loader',
38 },
39 ],
40 },
41 output: {
42 filename: '[name].js',
43 publicPath: '/',
44 },
45 };