Skip to content

Commit

Permalink
build: fix minification; can't use const in the JS file
Browse files Browse the repository at this point in the history
  • Loading branch information
timmywil committed Nov 15, 2019
1 parent d05f1e7 commit 75da8c2
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/polyfills.js
@@ -1,3 +1,4 @@
/* eslint-disable no-var */
// Support: IE11 only
if (window.NodeList && !NodeList.prototype.forEach) {
NodeList.prototype.forEach = Array.prototype.forEach
Expand All @@ -7,7 +8,7 @@ if (window.NodeList && !NodeList.prototype.forEach) {
if (typeof window.CustomEvent !== 'function') {
window.CustomEvent = function CustomEvent(event, params) {
params = params || { bubbles: false, cancelable: false, detail: null }
const evt = document.createEvent('CustomEvent')
var evt = document.createEvent('CustomEvent')
evt.initCustomEvent(event, params.bubbles, params.cancelable, params.detail)
return evt
}
Expand Down

0 comments on commit 75da8c2

Please sign in to comment.