Uploaded image for project: 'Compass '
  1. Compass
  2. COMPASS-8154

Move `adjustConnectionOptionsBeforeConnect` from connection-form into a new package

    • Developer Tools
    • 3

      The VSCode extension uses the `adjustConnectionOptionsBeforeConnect` function from `connection-form` when connecting in the main extension as it requires as similar connection flow. By having it in the connection-form we're unintentionally adding large frontend dependencies to the bundle and also slowing down startup time. (compass-components, and compass-editor are the main ones as they pull in leafygreen, code-mirror, and prettier, which add a lot).

      We should move this `adjustConnectionOptionsBeforeConnect` to a new place, I'm thinking either connection-info, or a new package, something like connection-utils.

      Before / after webpack excluding these dependencies screenshots attached. This method won't work since it'll give runtime errors.

      Before:

      After:

            Assignee:
            Unassigned Unassigned
            Reporter:
            rhys.howell@mongodb.com Rhys Howell
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: