Skip to content

Synchronous XMLHttpRequest on the main thread is depreciated #532

@netniV

Description

@netniV

Chrome is reporting depreciated request usage:

[Deprecation] Synchronous XMLHttpRequest on the main thread is deprecated because of its detrimental effects to the end user's experience. For more help, check https://xhr.spec.whatwg.org/.

    RequestIntercept = (function(_super) {
        __extends(RequestIntercept, _super);

        function RequestIntercept() {
            var monitorXHR, _this = this;
            RequestIntercept.__super__.constructor.apply(this, arguments);
            monitorXHR = function(req) {
                var _open;
                _open = req.open;
                return req.open = function(type, url, async) {
                    if (shouldTrack(type)) {
                        _this.trigger('request', {
                            type: type,
                            url: url,
                            request: req
                        });
                    }
                    return _open.apply(req, arguments);
                }
                ;
            }

The error appears against the return _open.apply(req, arguments);

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions