Skip to content

Commit 5f26c96

Browse files
allyoucanmapofftherailz
authored andcommitted
Fix #3147 Added polyfill for node.closest (ie11) (#3148)
1 parent 0f19785 commit 5f26c96

2 files changed

Lines changed: 10 additions & 1 deletion

File tree

buildConfig.js

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,15 @@ module.exports = (bundles, themeEntries, paths, extractThemesPlugin, prod, publi
1111
entry: assign({
1212
'webpack-dev-server': 'webpack-dev-server/client?http://0.0.0.0:8081', // WebpackDevServer host and port
1313
'webpack': 'webpack/hot/only-dev-server' // "only" prevents reload on syntax errors
14-
}, bundles, themeEntries),
14+
},
15+
// add polyfill library to all bundle
16+
Object.keys(bundles).reduce((bundlesEntry, key) =>
17+
assign({}, bundlesEntry,
18+
{[key]: [
19+
'element-closest', // node.closest polyfill for ie11
20+
bundles[key]]}),
21+
{}),
22+
themeEntries),
1523
output: {
1624
path: paths.dist,
1725
publicPath,

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,6 +99,7 @@
9999
"colorbrewer": "1.0.0",
100100
"create-react-class": "15.6.2",
101101
"css-tree": "1.0.0-alpha24",
102+
"element-closest": "2.0.2",
102103
"es6-promise": "2.3.0",
103104
"eventlistener": "0.0.1",
104105
"file-saver": "1.3.3",

0 commit comments

Comments
 (0)