Skip to content

Detect ES6 support in loader & fetch corresponding CDN bundle #53840

Closed

Description

@mydea

Currently, the Loader Script will always fetch the ES5 bundle, unless replay is enabled, then we always fetch the ES6 bundle (because replay does not support ES5).

This has two negative side effects:

  • When replay is not enabled, the majority of users that actually have an ES6 browser will get the less optimized ES5 version shipped
  • When replay is enabled, users with ES5 browsers will not get a working sentry instance.

I propose to detect ES6 support (e.g. via checking <script nomodule>, which should be good enough for our purposes), and then loading the ES6 bundles based on this. If replay is enabled and there is no ES6 support, we disable replay and load the replay-less ES5 bundle.

Activity

  1. self-assigned this
    on Jul 31, 2023
  2. locked and limited conversation to collaborators on Jun 11, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions