Rendering tests / add custom web worker loader

Also includes a change in the rollup-babel plugin to avoid
adding helpers as dependencies (which would give out errors).
This commit is contained in:
Olivier Guyot
2019-05-18 18:34:25 +02:00
parent 698816030e
commit 98b0c65450
2 changed files with 13 additions and 1 deletions

View File

@@ -22,5 +22,16 @@ module.exports = {
context: __dirname,
target: 'web',
entry: entry,
devtool: 'source-map'
devtool: 'source-map',
module: {
rules: [{
test: /\.js$/,
use: {
loader: path.join(__dirname, '../examples/webpack/worker-loader.js')
},
include: [
path.join(__dirname, '../src/ol/worker')
]
}]
}
};

View File

@@ -20,6 +20,7 @@ async function build(input, {minify = true} = {}) {
common(),
resolve(),
babel({
'externalHelpers': true,
'presets': [
[
'@babel/preset-env',