diff options
| author | Shpuld Shpuldson <shpuld@shpposter.club> | 2020-01-26 15:59:59 +0200 |
|---|---|---|
| committer | Shpuld Shpuldson <shpuld@shpposter.club> | 2020-01-26 15:59:59 +0200 |
| commit | c4beac5f894642e64f2818e43697b472b7a70847 (patch) | |
| tree | b5e64b7f4f19b8b15549b0b29e876e8eea724c16 /src/lib/event_target_polyfill.js | |
| parent | 7cfe1b05e8d16fcbb6eab3b42f19e464d57ea35b (diff) | |
| parent | b0b0fc403a57dca6837bc99a87c66609156af2b9 (diff) | |
Merge branch 'develop' into feat/emoji-reactions
Diffstat (limited to 'src/lib/event_target_polyfill.js')
| -rw-r--r-- | src/lib/event_target_polyfill.js | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/lib/event_target_polyfill.js b/src/lib/event_target_polyfill.js new file mode 100644 index 00000000..2042c770 --- /dev/null +++ b/src/lib/event_target_polyfill.js @@ -0,0 +1,9 @@ +import EventTargetPolyfill from '@ungap/event-target' + +try { + /* eslint-disable no-new */ + new EventTarget() + /* eslint-enable no-new */ +} catch (e) { + window.EventTarget = EventTargetPolyfill +} |
