fix(core): use ResizeObserver polyfill (#6360)

- Close https://github.com/toeverything/AFFiNE/issues/6359
This commit is contained in:
Brooooooklyn
2024-03-28 10:48:22 +00:00
parent c2847e2082
commit 7cd75824a4
7 changed files with 5 additions and 14 deletions

View File

@@ -1,8 +0,0 @@
import { ResizeObserver } from '@juggle/resize-observer';
// prevents the following error in development mode:
// ResizeOvserver loop limit exceeded
// https://github.com/petyosi/react-virtuoso/issues/875#issuecomment-1962897033
if (process.env.NODE_ENV !== 'production') {
window.ResizeObserver = ResizeObserver;
}