Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve performance of wp_common_block_scripts_and_styles. #4707

Closed
wants to merge 8 commits into from

Conversation

spacedmonkey
Copy link
Member

Trac ticket: https://core.trac.wordpress.org/ticket/58560


This Pull Request is for code review only. Please keep all other discussion in the Trac ticket. Do not merge this Pull Request. See GitHub Pull Requests for Code Review in the Core Handbook for more details.

Copy link
Member

@felixarntz felixarntz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This PR has a substantial performance benefit when using a block theme with theme support for wp-block-styles (see https://core.trac.wordpress.org/ticket/58560#comment:5), however there are some changes in here that I'd like other people's feedback on.

I think we should definitely move this forward, whether in time for WP 6.3, or alternatively for WP 6.4. I'll defer to other folks to decide that, depending on the feedback on the new themeStyle approach taken here.

src/wp-includes/blocks/index.php Outdated Show resolved Hide resolved
@oandregal
Copy link
Member

I've done some search, but it's difficult to pinpoint who was involved in this work, given all the moving code around between core and gutenberg. Playing by ear and pinging @aristath, as he has worked in this area, in case he can provide feedback.

Co-authored-by: Colin Stewart <79332690+costdev@users.noreply.github.com>
Copy link
Contributor

@costdev costdev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR @spacedmonkey! I left one nitpick that can be addressed here or in a follow-up "catch-all" commit, so it's not a blocker.

@spacedmonkey
Copy link
Member Author

Thanks for the PR @spacedmonkey! I left one nitpick that can be addressed here or in a follow-up "catch-all" commit, so it's not a blocker.

@costdev Feedback complete.

Copy link
Contributor

@costdev costdev left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the update @spacedmonkey!

Copy link
Contributor

@audrasjb audrasjb left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good to ship @spacedmonkey 👍

Copy link
Member

@mukeshpanchal27 mukeshpanchal27 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Let one non-blocker nitpick for test other then look good to go.

@spacedmonkey
Copy link
Member Author

Committed 30d6172

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
6 participants