[wp-trac] [WordPress Trac] #57864: Defer register inline script in WP_Widget

WordPress Trac noreply at wordpress.org
Wed Mar 15 11:37:07 UTC 2023


#57864: Defer register inline script in WP_Widget
--------------------------+---------------------------
 Reporter:  spacedmonkey  |       Owner:  spacedmonkey
     Type:  enhancement   |      Status:  closed
 Priority:  normal        |   Milestone:  6.3
Component:  Widgets       |     Version:  4.8.1
 Severity:  normal        |  Resolution:  fixed
 Keywords:  has-patch     |     Focuses:  performance
--------------------------+---------------------------
Changes (by spacedmonkey):

 * status:  assigned => closed
 * resolution:   => fixed


Comment:

 In [changeset:"55553" 55553]:
 {{{
 #!CommitTicketReference repository="" revision="55553"
 Widgets: Defer register inline script in `WP_Widget_Custom_HTML` and
 `WP_Widget_Text`.

 In [41376] an inline script was added to push `idBases` for the custom
 html and text widgets. However, this script is not used unless the widget
 script is output in the widget screen / customizer. Deferring registering
 this script until it is needed, results in a faster server response times.


 Props spacedmonkey, sakibmd, flixos90, westonruter.
 Fixes #57864.
 }}}

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/57864#comment:6>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list