Review main Merged Breaking

74030[!!!][TASK] Remove global jquery object window.$

Benjamin Franzke CR +2 V +2 Normal +77 −52 updated 03/28/22, 19:07

Commit message

The global window.$ accessor to the jQuery instance is now
no longer provided.
Global jQuery usage has been deprecated in #86438 with the
suggestion to use JavaScript modules instead. With the
integration of browser native ES6 modules jQuery should
now be loaded as a regular module.

Some remaining cases in acceptance test are removed.
$.active == 0 checks have been no-ops as jQuery.ajax
isn't used in those components anymore
(core AjaxRequest which uses fetch() is used instead),
therefore $.active always resolved to 0.
This reveals why the additional 0.5s timeout-hack had been
added there, the method is now explicitly marked as an
explicit timeout instead of a waiting-method.

Note that window.jQuery is still provided if the
bootstrap javascript module is loaded as bootstrap JS
needs to load jQuery from the global window object.
window.jQuery global will be removed once we drop
bootstrap jquery interop (which is another breaking change).

Review

  • Code review CR +2

    Imported before Forger kept the single votes, the next import adds them.

  • Verified V +2

    Imported before Forger kept the single votes, the next import adds them.

Issues 2

Files 13