[wp-trac] [WordPress Trac] #44371: Make sure all JS globals are explicitly assigned to the window.
WordPress Trac
noreply at wordpress.org
Sun Aug 19 13:32:30 UTC 2018
#44371: Make sure all JS globals are explicitly assigned to the window.
------------------------------+-------------------------
Reporter: omarreiss | Owner: omarreiss
Type: defect (bug) | Status: closed
Priority: normal | Milestone: 5.0
Component: General | Version:
Severity: normal | Resolution: fixed
Keywords: has-patch commit | Focuses: javascript
------------------------------+-------------------------
Changes (by omarreiss):
* status: assigned => closed
* resolution: => fixed
Comment:
In [changeset:"43577" 43577]:
{{{
#!CommitTicketReference repository="" revision="43577"
General: Explicitly assigns all JS globals to the window.
Many variables in the JavaScript were defined in the global scope without
being explicitly assigned to the window. When built with Webpack, the code
gets encapsulated in anonymous functions and those implicit globals get
assigned to the wrong scope. This patch prevents that from happening.
Fixes #44371. See #43731.
}}}
--
Ticket URL: <https://core.trac.wordpress.org/ticket/44371#comment:8>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list