👉 Dev note published: WordPress 6.9 Frontend Performance Field Guide
I'm working on a Dev Note which will detail all of the performance improvements in WordPress 6.9. See full list in Trac. In the mean time, here are a couple outlines:
Links below either point to a specific ticket or a Trac query for the group of tickets:
- Optimize loading of stylesheets by loading block styles on demand in classic themes, omitting styles for hidden blocks, increasing the inline style limit from 20K to 40K, and inlining minified stylesheets in block themes.
- Introduce the template enhancement output buffer.
- Improve script loading performance by adding support for
fetchpriority, printing script modules in the footer, and optimizing the emoji detection script. - Optimize database queries, caching, UTF-8 processing, and spawning WP Cron.
- Introduce the template enhancement output buffer.
- Script Loader:
- Load block styles on demand in classic themes.
- Increase inline style limit from 20K to 40K bytes
- Allow inlining of block theme stylesheets.
- Minify stylesheets for block themes.
- Omit scripts and styles for hidden blocks by default.
- Support specifying
fetchpriorityfor scripts and script modules. - Support printing script modules in the footer
- Convert emoji detection script to script module and move to footer.
- Spawn WP Cron at
shutdowninstead ofinit. - Optimize database queries and caching.
- Optimize UTF-8 processing.
- Improve RSS feed caching.
- Update Genericons in core themes to remove legacy code.
- And a few others.
See all [Type] Performance PRs and issues for Gutenberg 20.4–21.9.
- Fix layout shift caused by
videotag in Video block lackingwidthandheight - Fix: Avoid duplicate get_the_title() calls in render_block_core_post_featured_image()
- Add wp-env SPX profiler option
- Editor performance improvements
- Avatar: Optimize user control query
- Block Bindings: Move bindable attributes to privateContext.
- Block Comments: New 'useBlockComments' hook and perf improvements
- Block Editor: Avoid unbound requests in inserter selectors
- Block Editor: Deprecate block hovered global state
- Core Data: Always try to resolve entity permissions
- Document Settings: Lazy load post authors' data
- Editor: Improve the 'Design' sidebar panel performance
- Editor: Optimize queries for 'useAllowSwitchingTemplates' hook
- Editor: Optimize selector queries for Homepage and Posts Page actions
- Editor: Preload template lookup
- Editor: Try displaying intermediate results for hierarchical terms
- Image: Don't subscribe to current post changes
- Introduce
withSyncEventaction wrapper utility and proxyeventobject whenever it is not used (see existing dev note) - Latest Posts: Delay inspector control queries until the block is selected
- Latest Posts: Embed author in response
- List View: Delay block highlighting when moving the mouse over the items
- Navigation Link: Don't check validity when block editing is disabled
- Navigation Link: Improve performance by only requesting entities when selected
- Navigation Link: Optimize 'getBlockParentsByBlockName' selector call
- Pages: reuse embedded info for authors
- Pages: use embedded info for feature media
- Perf: Avoid busting the memo cache for
useDebounceoptions - Post Author: Optimize and improve user control queries
- Remove extra traverseBlockTree call
- Site Editor: Fix template lookup preloading for non-draft pages
- core-data: Try using cached permissions even when
_fieldsis present in the query - usePostActions: avoid fetching all templates (unbound request)