• Type: Icon: Bug Bug
    • Resolution: Unresolved
    • Priority: Icon: Critical - P2 Critical - P2
    • None
    • Affects Version/s: None
    • Component/s: None

      The public types emitted for bson.d.ts are wrong:

      Unable to find source-code formatter for language: typescript. Available languages are: actionscript, ada, applescript, bash, c, c#, c++, cpp, css, erlang, go, groovy, haskell, html, java, javascript, js, json, lua, none, nyan, objc, perl, php, python, r, rainbow, ruby, scala, sh, sql, swift, visualbasic, xml, yaml
      export declare namespace BSON {
          const ObjectId: typeof bson.ObjectID; //  notice the capital D in ID
          type ObjectId = bson.ObjectId;
          const ObjectID: typeof bson.ObjectID;
          type ObjectID = bson.ObjectID;
          // ...
      }
      

      This is really weird since we're importing the right type from the namespace:

      https://github.com/realm/realm-js/blob/1e1e48a0f906d471b4a046168ed8cd628ef2d70f/packages/realm/src/bson.ts#L27-L30

      We should be able to upgrade to bson@6 by now and this will fix the issue since that has removed ObjectID (capital D) entirely.

            Assignee:
            kraen.hansen@mongodb.com Kræn Hansen
            Reporter:
            unitosyncbot Unito Sync Bot
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

              Created:
              Updated: