[wp-trac] [WordPress Trac] #47419: If emojis or embeds JavaScript is not loaded, variable wp is undefined in the front-end.
WordPress Trac
noreply at wordpress.org
Wed May 29 14:01:40 UTC 2019
#47419: If emojis or embeds JavaScript is not loaded, variable wp is undefined in
the front-end.
--------------------------+------------------------------
Reporter: Shelob9 | Owner: (none)
Type: defect (bug) | Status: new
Priority: normal | Milestone: Awaiting Review
Component: General | Version:
Severity: normal | Resolution:
Keywords: | Focuses:
--------------------------+------------------------------
Comment (by swissspidy):
One should always use `window.wp = window.wp || {};` when working with
global variables like that in a plugin. Not sure if we can add this in
core by default as an inline script or something.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/47419#comment:1>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list