-
Type: Bug
-
Resolution: Fixed
-
Priority: Critical - P2
-
None
-
Affects Version/s: None
-
Component/s: None
Goals
Hi
I'm working on Mongodb Realm app, based on Reactjs in typescript.
Expected Results
At this moment I want to build the app successfully
Actual Results
at build :
./node_modules/realm/lib/browser/index.js Attempted import error: 'invalidateCache' is not exported from './util' (imported as 'util').
Steps to Reproduce
npm i realm@^10.0.0-rc.1
Code Sample
I installed v10.0.0-rc.1 but I got this error
./node_modules/realm/lib/browser/index.js Attempted import error: 'invalidateCache' is not exported from './util' (imported as 'util').
If I'm looking into realm/lib/browser/util.js , invalidateCache is well imported from ./cache :
import {invalidateCache, getRealmCache} from './cache';
But invalidateCache is not exported at all.
If I'm looking into realm/lib/browser/util.js, util is imported and invalidateCache():
import * as util from './util'; ... util.invalidateCache();
Something is missing. If util.invalidateCache(); is used to export the function in util.js, if not import invalidateCache from cache.js and use invalidateCache() directly.
Version of Realm and Tooling
- Realm JS SDK Version: 10.0.0-rc.1
- Node or React Native: 14.5
- Client OS & Version: mac
- Which debugger for React Native: ?/None
Thank you