diff --git a/src/utils/index.js b/src/utils/index.js index eabe418..22772a8 100644 --- a/src/utils/index.js +++ b/src/utils/index.js @@ -1,29 +1,5 @@ import I18n from '../i18n'; -/** - * Adds DOM polyfills that babel polyfill doesn't include - */ -export const addPolyfills = () => { - - if (!Element.prototype.matches) { - Element.prototype.matches = Element.prototype.msMatchesSelector || - Element.prototype.webkitMatchesSelector; - } - - if (!Element.prototype.closest) { - Element.prototype.closest = function(s) { - let el = this; - - do { - if (Element.prototype.matches.call(el, s)) return el; - el = el.parentElement || el.parentNode; - } while (el !== null && el.nodeType === 1); - return null; - }; - } - -} - /** * Helper to init the i18n class with a pre-defined or auto-detected locale. */