From 09ca440a5e218dbd48949fc213e9c85d7aaa312f Mon Sep 17 00:00:00 2001 From: Christopher Goh Date: Mon, 13 Jul 2020 11:47:42 +0800 Subject: [PATCH] Fix polyfills --- website/src/entry/main.tsx | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/website/src/entry/main.tsx b/website/src/entry/main.tsx index 4e38122c23..eb146b829c 100644 --- a/website/src/entry/main.tsx +++ b/website/src/entry/main.tsx @@ -1,5 +1,10 @@ // Import Sentry earliest to capture exceptions import 'bootstrapping/sentry'; +// core-js has issues with Promise feature detection on Edge, and hence +// polyfills Promise incorrectly. Importing this polyfill directly resolves that. +// This is necessary as PersistGate used in ./App uses `Promise.prototype.finally`. +// See: https://github.com/zloirock/core-js/issues/579#issuecomment-504325213 +import 'core-js/es/promise/finally'; import React from 'react'; import ReactDOM from 'react-dom';