[wp-trac] [WordPress Trac] #60749: Interactivity API: Avoid unnecessary processing of directives

WordPress Trac noreply at wordpress.org
Wed Mar 13 10:42:50 UTC 2024


#60749: Interactivity API: Avoid unnecessary processing of directives
-------------------------------------------------+-------------------------
 Reporter:  joemcgill                            |       Owner:  swissspidy
     Type:  defect (bug)                         |      Status:  closed
 Priority:  normal                               |   Milestone:  6.5
Component:  Editor                               |     Version:
 Severity:  normal                               |  Resolution:  fixed
 Keywords:  has-patch commit fixed-major dev-    |     Focuses:
  reviewed                                       |  performance
-------------------------------------------------+-------------------------
Changes (by swissspidy):

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


Comment:

 In [changeset:"57825" 57825]:
 {{{
 #!CommitTicketReference repository="" revision="57825"
 Interactivity API: Do not process directives when there aren't any.

 Short-circuits directive processing when the markup does not actually
 contain any `data-wp-*` attributes.
 This reduces function calls and memory usage for the best case scenario
 due to not involving `WP_HTML_Tag_Processor`.

 Reviewed by gziolo, swissspidy.
 Merges [57824] to the to the 6.5 branch.

 Props joemcgill, swissspidy, gziolo, cbravobernal, flixos90.
 Fixes #60749.
 }}}

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


More information about the wp-trac mailing list