You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
exportdeclarenamespaceBSON{constObjectId: typeofbson.ObjectID;// 👈 notice the capital D in IDtypeObjectId=bson.ObjectId;constObjectID: typeofbson.ObjectID;typeObjectID=bson.ObjectID;// ...}
This is really weird since we're importing the right type from the namespace:
Adding the same notes as in the corresponding PR description regarding being blocked:
The BSON package is currently using top-level await which currently prevents us from bundling if don't enable that feature. @kraenhansen has contributed a PR to BSON to alleviate this for us (see Jira ticket).
The way the base64 dependency is required by the React Native bundle, confuses Metro. We need to investigate this further, but our current suspicion is the use of a "sub-package" / "bundled dependency", in the sense that the vendored "base64" is resolved via a "package.json" which is included in a sub-directory of the "bson" package.
The public types emitted for
bson.d.ts
are wrong:This is really weird since we're importing the right type from the namespace:
realm-js/packages/realm/src/bson.ts
Lines 27 to 30 in 1e1e48a
We should be able to upgrade to
bson@6
by now and this will fix the issue since that has removedObjectID
(capital D) entirely.The text was updated successfully, but these errors were encountered: