Skip to content

Deprecated feature used in jQuery-3.7.1.js #2508

Closed

Description

@kkkxxx0310

Image

Activity

  1. MSNev commented on Apr 29, 2025

    @MSNev
    Collaborator

    This is by design, the SDK supports and handles many runtimes.

    Just because the SDK happens to attempt to use and hook the unload event (along with the beforeunload, pagehide, visibilitychange) is not a bug. Once the unload event is no longer support (as it is with other runtimes that we run in today) the SDK will continue to work.

    If you want to stop this warning, we have a several configurations that you can use
    disablePageUnloadEvents - this is an array of "names" (it defaults to empty) where you can tell us to "please" do not attempt to hook these events. For this specific case you can add the following to the configuration passed during initialization

    disablePageUnloadEvents: [ "unload" ],

    And now we will no longer attempt to use the "unload" event -- UNLESS, all of the other events are also not available.
    For example, if you tell use to not use "unload" and "beforeunload" and we happen to get loaded into a runtime that does not support the "visibilitychange" or "pagehide" then we WILL ignore this config and attempt to hook the default set including "unload" and "beforeunload".

  2. locked as resolved and limited conversation to collaborators on Sep 2, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions