From f027494be914a5a1d00e54e64913dedf9eaf73ed Mon Sep 17 00:00:00 2001 From: Jonas Jenwald Date: Mon, 20 Aug 2018 12:14:37 +0200 Subject: [PATCH] Add a `Symbol` polyfill, using core-js, to allow using `for...of` loops https://github.com/zloirock/core-js#ecmascript-symbol --- src/shared/compatibility.js | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/shared/compatibility.js b/src/shared/compatibility.js index 6ade96dc17ca65..d1417421b38e40 100644 --- a/src/shared/compatibility.js +++ b/src/shared/compatibility.js @@ -183,6 +183,14 @@ const hasDOM = typeof window === 'object' && typeof document === 'object'; String.fromCodePoint = require('core-js/fn/string/from-code-point'); })(); +// Support: IE +(function checkSymbol() { + if (globalScope.Symbol) { + return; + } + require('core-js/es6/symbol'); +})(); + } // End of !PDFJSDev.test('CHROME') // Provides support for Object.values in legacy browsers.