Uploaded image for project: 'Node.js Driver'
  1. Node.js Driver
  2. NODE-6543

Bson library broken in frontend projects since version 5.x

    • Type: Icon: Bug Bug
    • Resolution: Unresolved
    • Priority: Icon: Blocker - P1 Blocker - P1
    • None
    • Affects Version/s: 5.9.2, 6.9.0
    • Component/s: BSON
    • 2

      Please note: this is a regression, it works fine with version 4.x but since version 5.x it is broken for FE projects. Also tried on latest 6.x version.

      [ERROR] Top-level await is not available in the configured target environment ("chrome129.0", "edge129.0", "firefox115.0", "ios17.0", "safari17.0" + 5 overrides)

      Use Case

      As a developer
      I want to use the bson npm package in my frontend application
      So that it works fine with version 6.x just like it did in version 4.x

      User Experience

      When I set up a new Angular project, whenever using the bson package I get the following error:

      [ERROR] Top-level await is not available in the configured target environment ("chrome129.0", "edge129.0", "firefox115.0", "ios17.0", "safari17.0" + 5 overrides)

      Acceptance Criteria

      Implementation Requirements

      • Updating from version 4.x to a more recent version of bson (e.g. 5.x or 6.x) should work out of the box

       

      Documentation Requirements

      • DOCSP ticket, API docs, etc

      Follow Up Requirements

      • additional tickets to file, required releases, etc
      • if node behavior differs/will differ from other drivers, confirm with dbx devs what standard to aim for and what plan, if any, exists to reconcile the diverging behavior moving forward

            Assignee:
            warren.james@mongodb.com Warren James
            Reporter:
            borzifrancesco@gmail.com Francesco Borzì
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

              Created:
              Updated: