Commit 77a5d9db authored by Mike Greiling's avatar Mike Greiling

add polyfill for NodeList.prototype.forEach (unsupported in Internet Explorer)

parent b63c08b2
...@@ -12,3 +12,4 @@ import 'core-js/fn/symbol'; ...@@ -12,3 +12,4 @@ import 'core-js/fn/symbol';
// Browser polyfills // Browser polyfills
import './polyfills/custom_event'; import './polyfills/custom_event';
import './polyfills/element'; import './polyfills/element';
import './polyfills/nodelist';
if (window.NodeList && !NodeList.prototype.forEach) {
NodeList.prototype.forEach = function forEach(callback, thisArg = window) {
for (let i = 0; i < this.length; i += 1) {
callback.call(thisArg, this[i], i, this);
}
};
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment