Make WordPress Core

Changes between Initial Version and Version 31 of Ticket #58775


Ignore:
Timestamp:
09/25/2023 09:44:29 PM (15 months ago)
Author:
hellofromTonya
Comment:

Updating the description to include the details @spacedmonkey shared in #comment:20.

More context about this reasoning for this ticket shared during today's scrub:

Is this a performance ticket? No, as @flixos90 noted in today's scrub discussion:

Performance itself should not be changed by this commit, neither to the positive nor negative.

As @joemcgill shared, it gives the potential for optimization by performance plugins:

My understanding is that the intent is to allow these styles to be optimized by performance optimization plugins. Currently that's not possible because these are not output using the standard WP Scripts APIs.

As @flixos90 shared, it allows other styles dependencies:

The other benefit of the change is that it allows for other styles to depend on those styles. For example, additional WP Embed styles in a plugin could now use something like wp_enqueue_script( $handle, $stylehsheet_file, 'wp-embed-template' ), and it would ensure they are printed in the correct order

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #58775

    • Property Status changed from new to reopened
    • Property Focuses performance added
    • Property Owner set to spacedmonkey
    • Property Milestone changed from Awaiting Review to 6.4
    • Property Keywords 2nd-opinion revert added
  • Ticket #58775 – Description

    initial v31  
    55- print_embed_styles
    66
    7 Instead of manually build tags like this, is not great. As these values are hard to filter and control the output of. These places should all be replaced with `wp_add_inline_style` or use the `WP_Style` enqueueing system.
     7Instead of manually build tags like this, is not great. As these values are hard to filter and control the output of. These places should all be replaced with `wp_add_inline_style` or use the `WP_Style` enqueueing system.
     8
     9This change does the following.
     10* Allows plugins to include these styles in css optimize.
     11* Allows developers to unqueue these styles.
     12* Makes it easier to maintain the these styles, as all styles are output in the same way.
     13* Adds constituency to the code.