Performance improvements for registering block variations with callbacks

Background

In WordPress 5.8, the APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways. for registering blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience. variations was introduced, bringing new capabilities to developers. However, it soon became evident that generating these variations had a non-trivial performance cost, particularly when used for template-part and navigation-link in WordPress 5.9 and post-terms in WordPress 6.1.

The coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. of this issue was that these variations were being generated on every page load due to their registration using the init hook. This was inefficient, as the variations were only needed in the editor or for returning block data in the REST APIREST API The REST API is an acronym for the RESTful Application Program Interface (API) that uses HTTP requests to GET, PUT, POST and DELETE data. It is how the front end of an application (think “phone app” or “website”) can communicate with the data store (think “database” or “file system”) https://developer.wordpress.org/rest-api/.. This redundancy in loading led to unnecessary performance overhead, underscoring the need for a more streamlined approach.

What is changed

In WordPress 6.5, we’ve introduced $variation_callback as a new attribute in WP_Block_Type. This feature allows developers to register variation-building functions as callbacks rather than building variations before registration. With this approach, variations are constructed from this callback only when they are accessed for the first time. 

Consequently, the WP_Block_Type::get_variations() method was introduced as the primary means to access variations. This method skillfully checks for a callback in variation_callback and triggers the callback, but only during the first access of the variations. This efficient approach ensures that the callback is executed just once, optimizing performance by avoiding redundant processing on subsequent accesses. Additionally, this strategy aids in lazy loading, as variations no longer need to be loaded during registration.

Moreover, it integrates the get_block_type_variations filterFilter Filters are one of the two types of Hooks https://codex.wordpress.org/Plugin_API/Hooks. They provide a way for functions to modify data of other functions. They are the counterpart to Actions. Unlike Actions, filters are meant to work in an isolated manner, and should never have side effects such as affecting global variables and output., which provides a versatile mechanism for developers to modify the resulting variations. These enhancements reflect WordPress’s ongoing commitment to improving its developer-centric features and maintaining compatibility with existing functionalities.
In WordPress 6.5, a significant alteration is made to WP_Block_Type::$variations. The notable change involved transitioning the visibility of variations from public to private. This modification was specifically designed to necessitate the use of the PHPPHP The web scripting language in which WordPress is primarily architected. WordPress requires PHP 5.6.20 or higher magic __get method for accessing variations only via WP_Block_Type::get_variations().

Please note that the modifications to WP_Block_Type::$variations may introduce certain limitations that require developer attention. These are detailed in the “Developer Action” section below.

Lazy loading variations using variation_callback

To facilitate the lazy loading of variations, we can replace the traditional method of loading variations with a callback. This approach is exemplified in the case of GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ PR #56952, which is aimed at enhancing performance.

Previously, template-part variations were loaded as follows:

register_block_type_from_metadata(
    __DIR__ . '/template-part',
    array(
        'render_callback'    => 'render_block_core_template_part',
        'variations'         => build_template_part_block_variations(),
    )
);

To optimize this, we have transitioned to using a variation_callback:

register_block_type_from_metadata(
    __DIR__ . '/template-part',
    array(
        'render_callback'    => 'render_block_core_template_part',
        'variation_callback' => 'build_template_part_block_variations',
    )
);

It’s important to note that if both variations and variation_callback are defined, like in the following example:

register_block_type_from_metadata(
'block-name',
array(
'variations' => array( 'test-variation' => array( 'test-variations' ) ),
'variation_callback' => 'get_test_variations',
)
);

In this scenario, the variations array takes precedence, and the variation_callback will not be called.

Developer action required

With the addition of variations to the existing magic function framework in WP_Block_Type, a significant limitation emerges: the inability to modify variations by reference directly. This change impacts how variations were traditionally updated.

Consider these examples of updating variations by reference, which will no longer function as expected in WordPress 6.5:

$block_type->variations[] = array( 'test' => array( 'test' ) );
// or
$block_type->variations['example1'] = array( 'test' );

To overcome this limitation in WordPress 6.5, a workaround involving a temporary variable can be used. Here’s how you can modify the temporary variable and then reassign it back to $block_type->variations:

$variations = $block_type->variations;$variations[] = array( 'test' => array( 'test' ) );
$block_type->variations = $variations;
// Similarly$variations = $block_type->variations;
$variations['example1'] = array( 'test' );$block_type->variations = $variations;

Alternatively, to align with the latest updates and best practices in WordPress, you might consider using the get_block_type_variations filter (reference link).

Utilizing the get_block_type_variations filter for enhanced variation management

The introduction of the get_block_type_variations filter in WordPress 6.5 allows for the manipulation and customization of the variations array, providing greater flexibility in handling block variations.

Here’s an implementation example of the get_block_type_variations filter:

function modify_block_type_variations( $variations, $block_type ) {
// Example: Add a new variation
if ( 'block-name' === $block_type->name ) {
$variations[] = array(
'name' => 'new-variation',
'title' => __( 'New Variation', 'textdomain' ),
// Other variation properties...
);
}

return $variations;
}
add_filter( 'get_block_type_variations', 'modify_block_type_variations', 10, 2 );

In this example, the modify_block_type_variations function is hooked to the get_block_type_variations filter. It checks if the block type is ‘block-name‘ and then adds a new variation to the variations array. This function then returns the modified variations array.

By leveraging this filter, developers can dynamically adjust the variations according to specific requirements or conditions.

Please refer to #59969 for additional details on these changes.

Props to @adamsilverstein, @westonruter, @joemcgill, and @leonnugraha for reviewing this post.

#6-5, #block-api, #dev-notes, #dev-notes-6-5

Hallway Hangout: Let’s chat about WordPress Playground

With WordPress Playground gradually becoming a larger part of our day-to-day lives as developers, it’s time to chat about what the project should look like going forward. There is a proposal for a v2 of the Blueprints schema, and we could use your feedback on current and future use of Playground.

So let’s have a casual conversation on what would benefit you as developers.

How to join

If you’re interested in joining us, the Hallway Hangout will be on Monday, March 4, 2024 at 04:00 pm (16:00) UTC. A Zoom link will be shared in the #outreach Slack channel before the session starts. 

Everyone is welcome to join, regardless of whether it’s just to listen or actively participate. This session will be recorded and recapped here on the Make CoreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. blogblog (versus network, site).

As usual, Hallway Hangouts are conversational events where you, the WordPress community, can provide your feedback directly to contributors to WordPress. This feedback is invaluable in steering the direction of the overall project.

Agenda

On the whole, the biggest thing we want to accomplish with this event is to bring more awareness to the WordPress Playground project, which lets you experience WordPress directly from the browser (no complicated setup necessary). Give it a try →

With this goal in mind, @zieladam, the architect of Playground, and I would like to discuss:

  • The Playground Blueprints system and how it works
  • What existing features you find the most useful in your own work
  • What current features feel limiting
  • The missing features you’d like to see going forward

We hope that you all can join us and help shape the future of WordPress Playground.

Post reviewed by @zieladam.

#hallway-hangout, #outreach, #playground

Summary, Dev Chat, February 28, 2024

Start of the meeting in SlackSlack Slack is a Collaborative Group Chat Platform https://slack.com/. The WordPress community has its own Slack Channel at https://make.wordpress.org/chat/..

Announcements

WordPress 6.5 Beta 3 was released on February 27, 2024. Thanks to everyone involved and who came to help test.

Forthcoming Releases

Major releasemajor release A release, identified by the first two numbers (3.6), which is the focus of a full release cycle and feature development. WordPress uses decimaling count for major release versions, so 2.8, 2.9, 3.0, and 3.1 are sequential and comparable in scope.: 6.5

WordPress 6.5 Release Candidaterelease candidate One of the final stages in the version release cycle, this version signals the potential to be a final release to the public. Also see alpha (beta). 1 is scheduled for next week (see release schedule). A call for testing for BetaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. 3 was posted earlier today. See: Help test WordPress 6.5 Beta 3.

During open floor, @marybaum asked for confirmation on roles for the release party for next week:

GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/: 17.8.0

Gutenberg 17.8.0 released earlier today. The What’s new in Gutenberg 17.8? (28 February) post was published following the meeting.

Discussions

With this being the last Dev Chat before WP 6.5 RC1, the discussion focused on issues related to the release. Specifically, the Font Library, and organizing release squads for 6.6 (and 6.5 minors).

Font Library

This discussion begins here.

@swissspidy noted that some concerns were raised about the upload location, capabilities, and use (or not use) of attachments for storing metadata.

Background conversation starting in Slack, and following on these GitHubGitHub GitHub is a website that offers online implementation of git repositories that can easily be shared, copied and modified by other developers. Public repositories are free to host, private repositories require a paid subscription. GitHub introduced the concept of the ‘pull request’ where code changes done in branches by contributors can be reviewed and discussed before being merged be the repository owner. https://github.com/ issues (props @jorbin):

@youknowriad identified this as the next step:

I’d love if we can get an agreement on this https://github.com/WordPress/gutenberg/issues/59417 at this point it doesn’t seem like a consensus is possible, so I’m unsure how a decision like that is made.

The next step identified in the meeting is for the release tech leads (@davidbaumwald, @swissspidy, @get_dave, and @youknowriad) to make a decision about the next steps for this feature’s inclusion in this release based on the input that has already been given on the relevant tickets.

Organizing release squads for upcoming releases

As we’re nearing the end of the 6.5 release cycle, it’s a good time to start getting squads in place for the 6.6 and 6.5.x releases.

A previous Call for Volunteers was made, which included all three major release for the year. @marybaum volunteered to follow up an help wrangle a followup effort for the 6.6 release cycle.

@jorbin agreed to help identify folks who could help with release responsibilities for 6.5 minor releases, since he’s helped lead the minor releases during the 6.4 cycle.

Highlighted posts

The full list of posts from the last week in coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. can be read on the agenda at this link.

Open floor

See the previous note in Future Releases section about coordinating roles for the RC1 release, that was raised during open floor.

@poena pointed out that we did not discuss one topic on the agenda: “Should we reduce the number of leads?”. @joemcgill agreed to include this discussion in a future meeting agenda.

Following the meeting, @costdev asked for feedback on #60504. Mainly: Whether this is a blockerblocker A bug which is so severe that it blocks a release. and if so, how can we unblock it for the long term?

Props to @mikachan for reviewing.

#6-5, #dev-chat, #summary

WordCamp Asia 2024 Contributor Day Core and Core Editor tables

It’s that time of year again! Whether you’re joining Contributor DayContributor Day Contributor Days are standalone days, frequently held before or after WordCamps but they can also happen at any time. They are events where people get together to work on various areas of https://make.wordpress.org/ There are many teams that people can participate in, each with a different focus. https://2017.us.wordcamp.org/contributor-day/ https://make.wordpress.org/support/handbook/getting-started/getting-started-at-a-contributor-day/. in person in Taipei or following along online via the #contributor-day SlackSlack Slack is a Collaborative Group Chat Platform https://slack.com/. The WordPress community has its own Slack Channel at https://make.wordpress.org/chat/. channel, thank you and welcome!

In order to ensure that everything goes seamlessly on the day, you should consider installing a local development environment on your laptop beforehand. Conference venue wifi isn’t always the best, especially when there are many folks using it at once, and this prerequisite is much easier to accomplish over a stable, fast connection.

To start with, at a minimum, you’ll need to have the latest stable version of nodejs and npm, which you can find here: https://nodejs.org/en (LTS is the one CoreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. and GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ use) and Git installed locally (for core you can also use SVNSVN Subversion, the popular version control system (VCS) by the Apache project, used by WordPress to manage changes to its codebase.).

Depending on whether you’re planning to work on Core or Gutenberg, there are a few different options:

For Core, clone the repo and follow the instructions here to install the included development environment. Docker is a prerequisite for it, so if you pick this option, go ahead and install Docker first.

For the editor, clone the Gutenberg repo and you can then use the wp-env package, which also requires Docker.

Note that if you want to install both these environments simultaneously, the port that the core one runs on will conflictconflict A conflict occurs when a patch changes code that was modified after the patch was created. These patches are considered stale, and will require a refresh of the changes before it can be applied, or the conflicts will need to be resolved. with the Gutenberg test environment. The easiest workaround for this is to change the core port, either by editing the config file locally or setting it in the terminal before starting up the environment.

An alternative to these is wp-now, which is a more lightweight option that requires only node/npm. It’s based on wp-playground. Note that there have been issues with playground on Windows.

For those attending in person, we’ll be located in the Code Lounge (South Lounge) on the third floor.

It’s also required to create a WordPress.org account if you don’t already have one, and if you’re using GitGit Git is a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency. Git is easy to learn and has a tiny footprint with lightning fast performance. Most modern plugin and theme development is being done with this version control system. https://git-scm.com/., you’ll also need a GitHub.com account.

See you there, or online!

Thanks to @kirasong for reviewing and suggesting changes.

#contributor-day-2, #wordcamp

What’s new in Gutenberg 17.8? (28 February)

“What’s new in GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/…” posts (labeled with the #gutenberg-new tag) are posted following every Gutenberg release on a biweekly basis, showcasing new features included in each release. As a reminder, here’s an overview of different ways to keep up with Gutenberg.

What's new in Gutenberg 17.8

Gutenberg 17.8 has been released and is available for download!

With many contributors focused on the upcoming WordPress 6.5 release, this Gutenberg release prioritizes stability and bugbug A bug is an error or unexpected result. Performance improvements, code optimization, and are considered enhancements, not defects. After feature freeze, only bugs are dealt with, with regressions (adverse changes from the previous version) being the highest priority. fixes. Still, there are some new features worth noting below!

As a reminder, with WordPress 6.5 now in the betaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. phase, bug fixes from the Gutenberg pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party are backported to be included in 6.5, as needed. But new features in Gutenberg 17.8 will not be included in WordPress 6.5.

Grid layout variation

Grid is a new layout variation for the Group blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience. that allows you to display the blocks within the group as a grid. There are two options for the grid layout. “Auto” generates the grid rows and columns automatically using a minimum width for each item. “Manual” allows specifying the exact number of columns.

Grid child sizing

A grid of 9 images in the post editor with the first image taking up 2 rows and 2 columns, while the other images all occupy 1 row and 1 column.
Using row and column span to resize a grid item

Grid children can be resized to a specific number of rows/columns by changing the “Column Span” and “Row Span” settings under Styles > Dimensions in the block inspector.

Bulk export your patterns

A grid of patterns with three that are selected. A menu is open under "Edit 3 Items" with the "Export as JSON" option highlighted.
Bulk export selected patterns

Multiple patterns can now be exported at the same time. After selecting the patterns you’d like to export in the Patterns section of the Site Editor, choose “Export as JSONJSON JSON, or JavaScript Object Notation, is a minimal, readable format for structuring data. It is used primarily to transmit data between a server and web application, as an alternative to XML.” from the Bulk Edit menu to download a zip archive containing JSON export files for all of the selected patterns.

Browse and try alternative templates in the sidebarSidebar A sidebar in WordPress is referred to a widget-ready area used by WordPress themes to display information that is not a part of the main content. It is not always a vertical column on the side. It can be a horizontal rectangle below or above the content area, footer, header, or any where in the theme.

The Blog Home template is open in the editor, with the Template tab visible in the sidebar. A list of pattern previews shows under the heading "Transform Into:"
Browsing alternative templates in the sidebar

Templates and template parts now show similar, related templates in the sidebar. You can switch to an alternative template or template part in a single click!

Other Notable Highlights

  • AccessibilityAccessibility Accessibility (commonly shortened to a11y) refers to the design of products, devices, services, or environments for people with disabilities. The concept of accessible design ensures both “direct access” (i.e. unassisted) and “indirect access” meaning compatibility with a person’s assistive technology (for example, computer screen readers). (https://en.wikipedia.org/wiki/Accessibility)
    • Enter editing mode via Enter or Spacebar. (58795)
    • Font Library: display font collected with pagination instead of infinite scrolling. (58794)
  • Performance Improvements
    • Pattern Block: Batch replacing actions. (59075)
    • Block Editor: Move StopEditingAsBlocksOnOutsideSelect to Root. (58412)
  • The repository specific code of conduct has been removed in favor of using a shared code of conduct for all WordPress repositories. (59027)

Changelog

Full changelog available

Changelog

Features

  • Patterns: add bulk export patterns action. (58897)
  • Template editor/inspector: show and select related patterns. (55091)

Layout

  • Add toggle for grid types and stabilise Grid block variation. (59051 and 59116)
  • Add support for column and row span in grid children. (58539)

Enhancements

  • Patterns Page: Make categoryCategory The 'category' taxonomy lets you group posts / content together that share a common bond. Categories are pre-defined and broad ranging. action button compact. (59203)
  • Block Editor: Use hooksHooks In WordPress theme and development, hooks are functions that can be applied to an action or a Filter in WordPress. Actions are functions performed when a certain event occurs in WordPress. Filters allow you to modify certain functions. Arguments used to hook both filters and actions look the same. instead of HoC in ‘SkipToSelectedBlock’. (59202)
  • Font Library: Adds the ability to use generic() in font family names. (59103 and 59037)
  • REST APIREST API The REST API is an acronym for the RESTful Application Program Interface (API) that uses HTTP requests to GET, PUT, POST and DELETE data. It is how the front end of an application (think “phone app” or “website”) can communicate with the data store (think “database” or “file system”) https://developer.wordpress.org/rest-api/. Global Styles RevisionsRevisions The WordPress revisions system stores a record of each saved draft or published update. The revision system allows you to see what changes were made in each revision by dragging a slider (or using the Next/Previous buttons). The display indicates what has changed in each revision. Controller: Return single revision only when it matches the parent id. (59049)
  • CSSCSS Cascading Style Sheets. & Styling: Tweak link focus outline styles in HTMLHTML HyperText Markup Language. The semantic scripting language primarily used for outputting content in web browsers. anchor and custom CSS. (59048)
  • Data Views: Make ‘All pages’ view label consistent with template and patterns. (59009)
  • Script Modules APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways.: Script Modules add deregister option. (58830)
  • Block Hooks: Add help text to Plugins panel. (59371)

Custom Fields

  • Block Bindings: Lock editing of blocks by default. (58787)
  • Style engine: Rename at_rule to rules_groups and update test/docs. (58922)

Block Library

  • Gallery: Set the ‘defaultBlock’ setting for inner blocks. (59168)
  • Remove the navigation edit button because it leads to a useless screen. (59211)
  • Set the ‘defaultBlock’ setting for Columns & List blocks. (59196)
  • Update: Increase footnotes metaMeta Meta is a term that refers to the inside workings of a group. For us, this is the team that works on internal WordPress sites like WordCamp Central and Make WordPress. priority and separate footnotes meta registration. (58882)

Site Editor

  • Editor: Hide template part and post content blocks in some site editor contexts. (58928)
  • Tweak save hub button. (58917 and 59200)

Components

  • CustomSelect: Adapt component for legacy props. (57902)
  • Use Element.scrollIntoView() instead of dom-scroll-into-view. (59085)

Global Styles

  • Global style changes: Refactor output for a more flexible UIUI User interface and grouping. (59055)
  • Style theme variations: Add property extraction and merge utils. (58803)

Bug Fixes

  • Distraction Free Mode: fix ui toggling bugs. (59061)
  • Layout: Refactor responsive logic for grid column spans. (59057)
  • Interactivity API: Only add proxies to plain objects inside the store. (59039)
  • Cover Block: Restore overflow: Clip rule to allow border radius again. (59388)

List View

  • Editor: Do not open list view by default on mobile. (59016)
  • Create Block: Add missing viewScriptModule field. (59140)
  • Ignore the ‘twentytwentyfour’ test theme dir created by wp-env. (59072)
  • useEntityBlockEditor: Update ‘content’ type check. (59058)

Block Library

  • Author, Author Bio, Author Name: Add a fallback for Author Archive Template. (55451)
  • Fix Spacer orientation when inside a block with default flex layout. (58921)
  • Fix WP 6.4/6.3 compat for navigation link variations. (59126)
  • Interactivity API: Fix server side rendering for Search block. (59029)
  • Navigation: Avoid using embedded record from fallback API. (59076)
  • Pagination Numbers: Add data-wp-key to pagination numbers if enhanced pagination is enabled. (58189)
  • Revert “Navigation: Refactor mobile overlay breakpoints to JSJS JavaScript, a web scripting language typically executed in the browser. Often used for advanced user interfaces and behaviors. (#57520)”. (59149)
  • Spacer block: Fix null label in tooltip when horizontal layout. (58909)

Data Views

  • DataViews: Add loading/no results message in grid view. (59002)
  • DataViews: Correctly display featured imageFeatured image A featured image is the main image used on your blog archive page and is pulled when the post or page is shared on social media. The image can be used to display in widget areas on your site or in a summary list of posts. that don’t have image sizes. (59111)
  • DataViews: Fix pages list back path. (59201)
  • DataViews: Fix patterns, templates and template parts pagination z-index. (58965)
  • DataViews: Fix storybook. (58842)
  • DataViews: Remove second reset filter button in filterFilter Filters are one of the two types of Hooks https://codex.wordpress.org/Plugin_API/Hooks. They provide a way for functions to modify data of other functions. They are the counterpart to Actions. Unlike Actions, filters are meant to work in an isolated manner, and should never have side effects such as affecting global variables and output. dialog. (58960)
  • Revert footer in pages list with DataViews. (59151)

Block Hooks

  • Fix in Navigation block. (59021)
  • Take controlled blocks into account for toggle state. (59367)

Block Editor

  • After Enter transform, skip other onEnter actions like splitting. (59064)
  • Close link preview if collapsed selection when creating link. (58896)
  • Editor: Limit spotlight mode to the editor. (58817)
  • Fix incorrect useAnchor positioning when switching from virtual to rich text elements. (58900)
  • Inserter: Don’t select the closest block with ‘disabled’ editing mode. (58971)
  • Inserter: Fix title condition for media tab previews. (58993)

Site Editor

  • Fix navigation on mobile web. (59014)
  • Fix: Don’t render the Transform Into panel if there are no patterns. (59217)
  • Fix: Logical error in filterPatterns on template-panel/hooks.js. (59218)
  • Make command palette string transatables. (59133)
  • Remove left margin on Status help text. (58775)

Patterns

  • Allow editing of image block alt and title attributes in content only mode. (58998)
  • Avoid showing block removal warning when deleting a pattern instance that has overrides. (59044)
  • Block editor: Pass patterns selector as setting. (58661)
  • Fix pattern categories on import. (58926)
  • Site editor: Fix start patterns store selector. (58813)

Global Styles

  • Fix console error in block preview. (59112)
  • Revert “Use all the settings origins for a block that consumes paths with merge #55219” (58951 and 59101)
  • Shadows: Don’t assume that coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. provides default shadows. (58973)

Font Library

  • Fixes installed font families not rendering in the editor or frontend. (59019)
  • Font Library: Add missing translationtranslation The process (or result) of changing text, words, and display formatting to support another language. Also see localization, internationalization. functions. (58104)
  • Show error message when no fonts found to install. (58914)
  • Font Library: Create post types on init hook. (59333)

Synced Patterns

  • Fix missing source for binding attributes. (59194)
  • Fix resetting individual blocks to empty optional values for Pattern Overrides. (59170)
  • Fix upload button on overridden empty image block in patterns. (59169)

Design Tools

  • Background image support: Fix issue with background position keyboard entry. (59050)
  • Cover block: Clear the min height field when aspect ratio is set. (59191)
  • Elements: Fix block instance element styles for links applying to buttons. (59114)

Components

  • Modal: Add box-sizing reset style. (58905)
  • ToolbarButton: Fix text centering for short labels. (59117)
  • Upgrade Floating UI packages, fix nested iframeiframe iFrame is an acronym for an inline frame. An iFrame is used inside a webpage to load another HTML document and render it. This HTML document may also contain JavaScript and/or CSS which is loaded at the time when iframe tag is parsed by the user’s browser. positioning bug. (58932)

Post Editor

  • Editor: Fix ‘useHideBlocksFromInserter’ hook filename. (59150)
  • Fix layout for non viewable post types. (58962)

Rich Text

  • Fix link paste for internal paste. (59063)
  • Revert “Rich text: Pad multiple spaces through en/em replacement”. (58792)

Custom Fields

  • Block Bindings: Add block context needed for bindings in PHPPHP The web scripting language in which WordPress is primarily architected. WordPress requires PHP 5.6.20 or higher. (58554)
  • Block Bindings: Fix disable bindings editing when source is undefined. (58961)

Accessibility

  • Enter editing mode via Enter or Spacebar. (58795)
  • Block Bindings > Image Block:Mark connected controls as ‘readonly’. (59059)
  • Details Block: Try double enter to escape inner blocks. (58903)
  • Font Library: Replace infinite scroll by pagination. (58794)
  • Global Styles: Remove menubar role and improve complementary area headerHeader The header of your site is typically the first thing people will experience. The masthead or header art located across the top of your page is part of the look and feel of your website. It can influence a visitor’s opinion about your content and you/ your organization’s brand. It may also look different on different screen sizes. semantics. (58740)

Block Editor

  • Block Mover: Unify visual separator when show button label is on. (59158)
  • Make the custom CSS validation error message accessible. (56690)
  • Restore default border and focus style on image URLURL A specific web address of a website or web page on the Internet, such as a website’s URL www.wordpress.org input field. (58505)

Performance

  • Pattern Block: Batch replacing actions. (59075)
  • Block Editor: Move StopEditingAsBlocksOnOutsideSelect to Root. (58412)

Documentation

  • Add contributing guidlines around Component versioning. (58789)
  • Clarify the performance reference commit and how to pick it. (58927)
  • DataViews: Update documentation. (58847)
  • Docs: Clarify the status of the wp-block-styles theme support, and its intent. (58915)
  • Fix move interactivity schema to supports property instead of selectors property. (59166)
  • Storybook: Show badges in sidebar. (58518)
  • Theme docs: Update appearance-tools documentation to reflect opt-in for backgroundSize and aspectRatio. (59165)
  • Update richtext.md. (59089)

Interactivity API

  • Interactivity API: Fix WP version, update new store documentation. (59107)
  • Interactivity API: Update documentation guide with new wp-interactivity directive implementation. (59018)
  • Add interactivity property to block supports reference documentation. (59152)

Schemas

  • Block JSON schema: Add viewScriptModule field. (59060)
  • Block JSON schema: Update shadow definition. (58910)
  • JSON schema: Update schema for background support. (59127)

Code Quality

  • Create Block: Remove deprecated viewModule field. (59198)
  • Editor: Remove the ‘all’ rendering mode. (58935)
  • Editor: Unify the editor commands between post and site editors. (59005)
  • Relocate ‘ErrorBoundary’ component unit testunit test Code written to test a small piece of code or functionality within a larger application. Everything from themes to WordPress core have a series of unit tests. Also see regression. folders. (59031)
  • Remove obsolete wp-env configuration from package.json (#58877). (58899)
  • Design Tools > Elements: Make editor selector match theme.json and frontend. (59167)
  • Global Styles: Update sprintf calls using _n. (59160)
  • Block API: Revert “Block Hooks: Set ignoredHookedBlocks metada attr upon insertion”. (58969)
  • Editor > Rich Text: Remove inline toolbar preference. (58945)
  • Style Variations: Remove preferred style variations legacy support. (58930)
  • REST API > Template Revisions: Move from experimental to compat/6.4. (58920)

Block Editor

  • Block-editor: Auto-register block commands. (59079)
  • BlockSettingsMenu: Combine ‘block-editor’ store selectors. (59153)
  • Clean up link control CSS. (58934)
  • HeadingLevelDropdown: Remove unnecessary isPressed prop. (56636)
  • Move ‘ParentSelectorMenuItem’ into a separate file. (59146)
  • Remove ‘BlockSettingsMenu’ styles. (59147)

Components

  • Add Higher Order Function to ignore Input Method Editor (IME) keydowns. (59081)
  • Add lint rules for theme color CSS var usage. (59022)
  • ColorPicker: Style without accessing InputControl internals. (59069)
  • CustomSelectControl (v1 & v2): Fix errors in unit test setup. (59038)
  • CustomSelectControl: Hard deprecate constrained width. (58974)

Post Editor

  • DocumentBar: Fix browser warning error. (59193)
  • DocumentBar: Simplify component, use framer for animation. (58656)
  • Editor: Remove unused selector value from ‘PostTitle’. (59204)
  • Editor: Unify Mode Switcher component between post and site editor. (59100)

Interactivity API

  • Refactor to use string instead of an object on wp-data-interactive. (59034)
  • Remove data-wp-interactive object for core/router. (59030)
  • Use data_wp_context helper in core blocks and remove data-wp-interactive object. (58943)

Site Editor

  • Add stylelint rule to prevent theme CSS vars outside of wp-components. (59020)
  • Don’t memoize the canvas container title. (59000)
  • Remove old patterns list code and styles. (58966)

Tools

  • Remove reference to CODE_OF_CONDUCT.md in documentation. (59206)
  • Remove repository specific Code of Conduct. (59027)
  • env: Fix mariadb version to LTS. (59237)

Testing

  • Components: Add sleep() before all Tab() to fix flaky tests. (59012)
  • Components: Try fixing some flaky Composite and Tabs tests. (58968)
  • Migrate change-detection to Playwright. (58767)
  • Tabs: Fix flaky unit tests. (58629)
  • Update test environment default theme versions to latest. (58955)
  • Performance tests: Make site editor performance test backwards compatible. (59266)
  • Performance tests: Update selectors in site editor pattern loading tests. (59259)
  • Fix failing Dropdown Menu e2e tests. (59356)

Build Tooling

  • Add test:e2e:playwright:debug command to debug Playwright tests. (58808)
  • Updating Storybook to v7.6.15 (latest). (59074)

Contributors

The following contributors merged PRs in this release:

@aaronrobertshaw @afercia @ajlende @alexstine @andrewhayward @andrewserong @brookewp @c4rl0sbr4v0 @chad1008 @ciampo @creativecoder @DAreRodz @derekblank @desrosj @draganescu @ellatrix @fabiankaegy @gaambo @glendaviesnz @jameskoster @janboddez @jasmussen @jeryj @jorgefilipecosta @jsnajdr @juanfra @kevin940726 @Mamaduka @MarieComet @matiasbenedetto @mirka @noisysocks @ntsekouras @oandregal @ockham @pbking @ramonjd @SantosGuillamot @scruffian @shreyash3087 @t-hamano @talldan @tellthemachines @tyxla @youknowriad

Props to @saxonafletcher for assisting with visual assets and to @mikachan and @jorbin for reviewing this post before publishing.

#block-editor, #core-editor, #gutenberg, #gutenberg-new

Agenda, Dev Chat, Wednesday February 28, 2024

The next WordPress Developers Chat will take place on  Wednesday February 28, 2024 at 20:00 UTC in the core channel on Make WordPress Slack.

The live meeting will focus on the discussion of proposals and releases, updates on 6.5, and have an open floor section.

Additional items will be referred to in the various curated agenda sections, as below. If you have ticketticket Created for both bug reports and feature development on the bug tracker. requests for help, please do continue to post details in the comments section at the end of this agenda.

Announcements

WordPress 6.5 Beta 3 was released on February 27, 2024. Thanks to everyone involved and who came to help test.

Forthcoming releases

Next major releasemajor release A release, identified by the first two numbers (3.6), which is the focus of a full release cycle and feature development. WordPress uses decimaling count for major release versions, so 2.8, 2.9, 3.0, and 3.1 are sequential and comparable in scope.: 6.5

Updates from the release squad can be shared in the Dev Chat.

Next GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ release: 17.8

Gutenberg 17.8 is scheduled for released today and will include the these issues.

Discussions

This week the discussion will focus on any final priority topics that need to be raised prior to 6.5 RCrelease candidate One of the final stages in the version release cycle, this version signals the potential to be a final release to the public. Also see alpha (beta). 1.

Proposed topics

Feel free to suggest additional topics related to this release in the comments.

Highlighted posts

CoreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress.-editor Updates

Props to @annezazu for collating and sharing this list.

Tickets for assistance

Tickets for 6.5 will be prioritized.
Please include detail of tickets / PR and the links into comments, and if you intend to be available during the meeting if there are any questions or will be async.

Open floor

Items for this can be shared in the comments.

#6-5, #agenda, #dev-chat

I18N Improvements in 6.5 (Performant Translations)

Various internationalization (i18n) improvements are in WordPress 6.5, and this developers note will focus on these.

New localization system with improved performance

Over the past year, WordPress contributors have meticulously analyzed performance of the existing i18ni18n Internationalization, or the act of writing and preparing code to be fully translatable into other languages. Also see localization. Often written with a lowercase i so it is not confused with a lowercase L or the numeral 1. Often an acquired skill. system in WordPress and ultimately created a new Performant Translations feature pluginFeature Plugin A plugin that was created with the intention of eventually being proposed for inclusion in WordPress Core. See Features as Plugins. that provided a completely overhauled system with significantly better performance. After thousands of betaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. testers and a merge announcement late last year, this new library is now included in WordPress 6.5! See #59656 for all the details.

The Performant Translations pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party is still useful and will continue to be maintained to build on top of the coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. solution with a distinct additional feature. As is already the case today, the plugin will automatically convert any .mo files to PHPPHP The web scripting language in which WordPress is primarily architected. WordPress requires PHP 5.6.20 or higher files if a PHP file does not currently exist. This is useful for sites where translations are not coming from translate.wordpress.org or only exist locally on that server.

This new library is faster at loading binary .mo files and uses less memory. It even supports loading multiple locales at the same time, which makes locale switching faster. In addition to that, it supports translations contained in PHP files, avoiding a binary file format and leveraging OPCache if available.

The new library is so fast, in fact, that it paves the way for the Preferred Languages feature plugin to merge translations of multiple locales by default starting with WordPress 6.5.

While this is in large part a silent and backward-compatible under-the-hood change, there are still a few things to be aware of:

New .l10n.php translationtranslation The process (or result) of changing text, words, and display formatting to support another language. Also see localization, internationalization. file format

When downloading language packs from WordPress.orgWordPress.org The community site where WordPress code is created and shared by the users. This is where you can download the source code for WordPress core, plugins and themes as well as the central location for community conversations and organization. https://wordpress.org/, there will be a new .l10n.php file in addition to the .mo and .po files you are already familiar with. If an .mo translation file has a corresponding .l10n.php file, the latter will be loaded instead, making things even faster and use even less memory.

This is a progressive enhancementenhancement Enhancements are simple improvements to WordPress, such as the addition of a hook, a new feature, or an improvement to an existing feature., so if there’s only an .mo file but no PHP file, translations will still be loaded as expected. However, the opposite is also true! So you can theoretically use only .l10n.php translation files in your project and features such as the just-in-time translation loading continue to work. Right now, WordPress still expects corresponding .po and .mo files for things like update checks. However, this limitation will be addressed in the future, see #60554 for more information.

Note: if you don’t see any .l10n.php translation files in wp-content/languages yet, it might be that the language pack hasn’t been updated in a while, i.e. there were no new translations.

Here’s an example of a PHP translation file as supported by WordPress 6.5:

<?php
return [
'project-id-version' => 'WordPress - 6.5.x - Development',
'report-msgid-bugs-to' => 'polyglots@example.com',
'messages' =>
[
'original' => 'translation',
'contextEOToriginal with context' => 'translation with context',
'plural0' => 'translation0' . "\0" . 'translation1',
'contextEOTplural0 with context' => 'translation0 with context' . "\0" . 'translation1 with context',
'Product' => 'Produkt' . "\0" . 'Produkte',
],
];

Note: EOT here stands for the “End of Transmission” character (U+0004, or "\4" in PHP). It’s the same delimiter as in gettext used to glue the context with the singular string.

Generating PHP translation files

If you would like to generate these PHP translation files yourself, version 4.0 of GlotPress, the plugin that powers translate.WordPress.org, already supports the new .l10n.php format.

In addition to that, WP-CLI 2.10.0 (i18n-command 2.6.0) provides a new wp i18n make-php command to create these PHP files from a given .po file. Examples:

# Create PHP files for all PO files in the current directory.
$ wp i18n make-php .

# Create a PHP file from a single PO file in a specific directory.
$ wp i18n make-php example-plugin-de_DE.po languages

If you are developing a WordPress plugin that deals with translations, you can also use the new WP_Translation_File class to convert an .mo file into a PHP file. Example:

$contents = WP_Translation_File::transform( $mofile, 'php' );
if ( $contents ) {
file_put_contents( $path_to_php_file, $contents );
}

New filters to customize this behavior

If you would like to disable the support for PHP files for some reason; for example, if you don’t have any yet in your project and want to prevent the extra file lookup operation, you can use the new translation_file_format filterFilter Filters are one of the two types of Hooks https://codex.wordpress.org/Plugin_API/Hooks. They provide a way for functions to modify data of other functions. They are the counterpart to Actions. Unlike Actions, filters are meant to work in an isolated manner, and should never have side effects such as affecting global variables and output. to change the preferred format (default is php) like so:

add_filter(
'translation_file_format',
static function () {
return 'mo';
}
);

The existing load_textdomain_mofile filter can still be used to filter the .mo file path for loading translations for a specific text domain. However, it only works for .mo files. To filter the path for a translation file, be it a .l10n.php or a .mo file, use the new load_translation_file filter.

Working with the $l10n global variable

Previously, when loading translations, WordPress would store an instance of the MO class in the $l10n global variable. With WordPress 6.5, this will be an instance of a new WP_Translations class that acts as a shim with similar characteristics. If your project directly works with this global variable or the MO class in some way, this is an area to keep an eye on.

Cached list of language file paths

This another slight performance improvement but unrelated to the new localization library covered above.

In places such as get_available_languages() and WP_Textdomain_Registry, WordPress used to directly use the glob() function to retrieve all .mo files in a specific directory. This is important for just-in-time translation loading and generally knowing which translations are installed. However, on sites with a large number of language files, the glob() operation can become expensive.

Because of this, a new caching mechanism was introduced in #58919 / [57287]. The file lookup is now handled centrally in WP_Textdomain_Registry and stored in the object cache in the translations group, with the cache key having the format cached_mo_files_<hash>, where <hash> is the MD5 hash of the scanned directory, e.g. wp-content/languages. The cache is cleared whenever language packs are updated.

Also, the lookup now also scans for .l10n.php files in addition to .mo files, in case only the former exist on a site.

More questions? Please let us know

If you have any questions, please leave a comment below or file a new ticket on Trac under the I18N component if you’ve encountered any bugs.

Props to @joemcgill, @stevenlinx for review.

#6-5, #dev-notes, #dev-notes-6-5, #i18n

Summary of Hallway Hangout on overlapping problems in the Site Editor

This is a summary of a Hallway Hangout that was first announced on Make Core. The aim was to have a shared space where we could talk synchronously about overlapping problems facing the site editing experience.

Video Recording:

Notes:

Notes are somewhat provided by some AI tooling but, unfortunately, wasn’t quite on point enough for me to use entirely. If anything is off or missing, please let me know.

The hallway hangout focused on discussing issues and problems users experience with the Site Editor, including changing something across an entire site or just for one blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience., pervasive inconsistencies in user interfaces, understanding inherited values and options, and determining what can and cannot be edited. This came out of a public blog post on the topic.

We discussed the need to improve documentation and educate users to help address these overlapping problems. We chatted about the what’s underneath the desire to not ship any new features and that some of these areas of problems require new features to be fixed. We discussed how some GutenbergGutenberg The Gutenberg project is the new Editor Interface for WordPress. The editor improves the process and experience of creating new content, making writing rich content much simpler. It uses ‘blocks’ to add richness rather than shortcodes, custom HTML etc. https://wordpress.org/gutenberg/ features are released in stages across various releases ultimately paving the way for greater work to be done, like Block HooksHooks In WordPress theme and development, hooks are functions that can be applied to an action or a Filter in WordPress. Actions are functions performed when a certain event occurs in WordPress. Filters allow you to modify certain functions. Arguments used to hook both filters and actions look the same. released in 6.4 and expanded upon for 6.5. Another example that was mentioned was content-only locking, which was added into a release without a UIUI User interface as it was a foundational part of a larger roadmap (overriding content in patterns needed this work for example). Part of what needs to be done here to is to better communicating how new features connect to and build upon each other. In many cases, polishing these experiences and reducing confusion has been a major focus of many of the last releases.

We discussed how it feels like we’re caught in between right now and there are different UI experiences floating around between the customizerCustomizer Tool built into WordPress core that hooks into most modern themes. You can use it to preview and modify many of your site’s appearance settings., site editor, and then page builders building on top. In a perfect world, the page builders use what’s being built in coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress. and the experience of using blocks feels more natural, whether just in the block editor or in the site editor (instead of those feeling like different experiences). It’s also tricky to come up with solutions that don’t just surface the complexity without providing clarity too. It’s both the most rewarding and most difficult to cover the wide range of use cases WordPress seeks to cover.

We chatted about using the experimental flag in Gutenberg pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party to allow incremental exploration before features are merged to core for some features. Tensions exist between accumulating features quickly in Gutenberg vs bottleneck of merging to core releases. Folks want to see more efforts made to document feature decisions and UI changes at the same level as core tickets, with complete descriptions. Getting feedback into UI decisions as much as possible will help with this too as we should make changes based on feedback and design direction combined. It would be great if more hosts ran the Gutenberg plugin directly and gave feedback to help with this. At this point, the #outreach channel was plugged as was the new outreach group in GitHubGitHub GitHub is a website that offers online implementation of git repositories that can easily be shared, copied and modified by other developers. Public repositories are free to host, private repositories require a paid subscription. GitHub introduced the concept of the ‘pull request’ where code changes done in branches by contributors can be reviewed and discussed before being merged be the repository owner. https://github.com/ to pingPing The act of sending a very small amount of data to an end point. Ping is used in computer science to illicit a response from a target server to test it’s connection. Ping is also a term used by Slack users to @ someone or send them a direct message (DM). Users might say something along the lines of “Ping me when the meeting starts.” folks who have opted in to provide feedback.

We discussed differentiating user capabilities for blocks and experiences based on user roles and the context of what they are trying to do on a site. More work needs to be done to explore and improve user capabilities. It was suggested that having more Core team members build real sites could help surface important issues and help prioritize work. Right now, we do see this happening with the Create Block Theme allowing folks to build block themes directly with the Site Editor and surface gaps. The same is true of each time a default theme is made and the gaps that are surfaced and fixed as a result. As much as possible, building real sites or working with folks who do has always been and remains critical.

Feedback from folks in the agency space centered around how agencies can’t ensure brand standards due to inability to lock down with GitGit Git is a free and open source distributed version control system designed to handle everything from small to very large projects with speed and efficiency. Git is easy to learn and has a tiny footprint with lightning fast performance. Most modern plugin and theme development is being done with this version control system. https://git-scm.com/. when content can change in the editor. It’s important to find ways to reassure clients that brand standards can still be ensured with new workflows. The same problem exists on the broader WordPress.orgWordPress.org The community site where WordPress code is created and shared by the users. This is where you can download the source code for WordPress core, plugins and themes as well as the central location for community conversations and organization. https://wordpress.org/ site so there are big opportunities for learnings and feedback. In some cases, folks tried the Site Editor last year and need to be invited back in with the latest & greatest to try once more with additional plugins to fill the gaps for now. In other cases, folks are successfully using it. Opened this developer blog idea after the fact to have agencies start sharing how they’ve successfully used the Site Editor process wise.

A new “overlapping problem” that @annezazu will add to the post is around the swirling experience of gradual adoption, extension, and curating of the editing experience. How do we make it as seamless as possible and have it make sense to folks? Expect the post to be updated with more thoughts there.

Towards the end, we also discussed issues everyday users face with site editing, the need for better onboarding, and a call to join more WordPress meetupMeetup All local/regional gatherings that are officially a part of the WordPress world but are not WordCamps are organized through https://www.meetup.com/. A meetup is typically a chance for local WordPress users to get together and share new ideas and seek help from one another. Searching for ‘WordPress’ on meetup.com will help you find options in your area. events. The “usual suspects” came up particularly around editing the homepage, the pain of the template hierarchy being exposed, missing settings in the Site Editor, etc. We also discussed an unfortunate experience someone had in giving feedback but feeling very dismissed. This is not something any of us want anyone to feel and it’s important we engage constructively. We also discussed how the majority still use classic themes and the importance of respecting both in discussions.

To close, we talked about how these are the toughest problems to solve! They are not easy by design and there’s a lot of appreciation for everyone who is willing to engage in these topics. We’re very much listening and I wouldn’t have been able to write the post to begin with if we weren’t. The biggest next step is to hold an additional hallway hangout in the future around one of these areas with a large design presence to help present solutions, discuss potential drawbacks, and see how we can move forward.

#gutenberg, #hallway-hangout, #outreach, #site-editor

Performance Chat Summary: 27 February 2024

Meeting agenda here and the full chat log is available beginning here on Slack.

Announcements

  • Welcome to our new members of #core-performance
  • WordPress BetaBeta A pre-release of software that is given out to a large group of users to trial under real conditions. Beta versions have gone through alpha testing in-house and are generally fairly close in look, feel and function to the final product; however, design changes often occur as part of the process. 3 is today
  • Discussion around any WordPress 6.5 tickets [link]
    • Dev notesdev note Each important change in WordPress Core is documented in a developers note, (usually called dev note). Good dev notes generally include a description of the change, the decision that led to this change, and a description of how developers are supposed to work with that change. Dev notes are published on Make/Core blog during the beta phase of WordPress release cycle. Publishing dev notes is particularly important when plugin/theme authors and WordPress developers need to be aware of those changes.In general, all dev notes are compiled into a Field Guide at the beginning of the release candidate phase. for this release were discussed
    • Please check https://github.com/orgs/WordPress/projects/154?query=is%3Aopen+sort%3Aupdated-desc for progress on all dev notes

Priority Projects

Server Response Time

Notes from today’s meeting:

  • @joemcgill #59532 was fixed last week and some unit testunit test Code written to test a small piece of code or functionality within a larger application. Everything from themes to WordPress core have a series of unit tests. Also see regression. improvements were added thanks to @thekt12
  • @thekt12 Working on implementing caching using transient for non-persistant cache website #59719 I have drafted an initial PR for just blockBlock Block is the abstract term used to describe units of markup that, composed together, form the content or layout of a webpage using the WordPress editor. The idea combines concepts of what in the past may have achieved with shortcodes, custom HTML, and embed discovery into a single consistent API and user experience. pattern  PR – https://github.com/WordPress/wordpress-develop/pull/6137
  • @joemcgill The past couple weeks, I’ve been mostly profiling the 6.5 betas against 6.4.3 to see why were are seeing a net server-timing regressionregression A software bug that breaks or degrades something that previously worked. Regressions are often treated as critical bugs or blockers. Recent regressions may be given higher priorities. A "3.6 regression" would be a bug in 3.6 that worked as intended in 3.5. in spite of the improvements we’ve made. So far, I haven’t found a clear cause or opportunity to avoid the regression but am continuing to look. More eyes would be helpful for sure.
  • @spacedmonkey There are 1020 matches for register_block_pattern in the pluginPlugin A plugin is a piece of software containing a group of functions that can be added to a WordPress website. They can extend functionality or add new features to your WordPress websites. WordPress plugins are written in the PHP programming language and integrate seamlessly with WordPress. These can be free in the WordPress.org Plugin Directory https://wordpress.org/plugins/ or can be cost-based plugin from a third-party repo – https://wpdirectory.net/search/01HQNNQ2VPN4CKBQYKCQEC7Y87

Database Optimization

Notes from today’s meeting:

  • @flixos90 I’m planning to get back to looking at the PR for #42441 later this week

JavaScriptJavaScript JavaScript or JS is an object-oriented computer programming language commonly used to create interactive effects within web browsers. WordPress makes extensive use of JS for a better user experience. While PHP is executed on the server, JS executes within a user’s browser. https://www.javascript.com/. & CSSCSS Cascading Style Sheets.

  • Link to the GitHub project board
  • Contributors: @mukesh27 @flixos90 @westonruter @thelovekesh
  • Projects from the 2024 roadmap:
    • INP opportunities research
    • Interactivity APIAPI An API or Application Programming Interface is a software intermediary that allows programs to interact with each other and share data in limited, clearly defined ways.
    • Speculative prerendering
    • Embed Optimizer

Notes from today’s meeting:

  • @westonruter the Embed Optimizer is ready for initial submission to the directory
  • @thelovekesh Web Worker offloading aka Partytown module is ready for final review. Since INP date is coming soon and it provides a good opportunity to offload 3P scripts, I think we can move forward with it

Images

  • Link to the GitHub project board
  • Contributors: @flixos90 @adamsilverstein @joemcgill @westonruter
  • Projects from the 2024 roadmap:
    • Optimization Detective (formerly Image loading optimization)
    • API to facilitate more accurate “sizes” attribute
    • Land AVIF support in coreCore Core is the set of software required to run WordPress. The Core Development Team builds WordPress.
    • Client side image compression

Notes from today’s meeting:

  • @westonruter For Optimization Detective (formerly Image Loading Optimization), this PR needs review: https://github.com/WordPress/performance/pull/988
  • @adamsilverstein AVIF support is landed a while back and the dev note published. also in 6.5 we’ll have progressive image support (which will be mentioned in the field guideField guide The field guide is a type of blogpost published on Make/Core during the release candidate phase of the WordPress release cycle. The field guide generally lists all the dev notes published during the beta cycle. This guide is linked in the about page of the corresponding version of WordPress, in the release post and in the HelpHub version page.)

Measurement

Notes from today’s meeting:

  • @joemcgill The only thing currently in progress related to this is the fixes to the 6.4 performance tests, which @thelovekesh volunteered to work on recently.

Ecosystem Tools

Notes from today’s meeting:

  • @mukesh27 for Creating standalone plugins milestone 2b:
    • PRs that have been merged:
      • PR #999 – Move Auto Sizes plugin assets to plugins folder
      • PR #1014 – Fix unit test for Multisitemultisite Used to describe a WordPress installation with a network of multiple blogs, grouped by sites. This installation type has shared users tables, and creates separate database tables for each blog (wp_posts becomes wp_0_posts). See also network, blog, site
    • PRs ready for Review:
      • PR #1000 – Implement publishing workflow for standalone plugins that aren’t modules
      • PR #1002 – Separate phpcs.xml.dist Files for Each Plugin to Isolate Text Domains
      • PR #1011 – Move published modules to standalone plugins (Another contributor @thelovekesh is working on this)
  • @thelovekesh Aside, I have started a discussion on improving the DX in new monorepo setup – https://github.com/WordPress/performance/issues/1012

Open Floor

  • @pbearne I have been working on the old core performance tickets. Clearing out won’t fix and refreshing the code as needed. if anybody wants me to jump to a later ticketticket Created for both bug reports and feature development on the bug tracker., pingPing The act of sending a very small amount of data to an end point. Ping is used in computer science to illicit a response from a target server to test it’s connection. Ping is also a term used by Slack users to @ someone or send them a direct message (DM). Users might say something along the lines of “Ping me when the meeting starts.” me
  • @johnbillion What’s the process for adding the [Focus] ... label to an issue? Is that for categorisation or only for issues that are an active focus for each team?
    • @flixos90 It’s categorization primarily. We have never had anything (at least as far as I remember) that didn’t fit in one of the existing focus groups
    • @joemcgill I believe that they used to align to the original project boards that were set up on the repo, which have evolved over the past few years, so they probably need a refresh at some point. Currently, I agree we’re not really using them for any reason

Our next chat will be held on Tuesday, March 5, 2024 at 16:00 UTC in the #core-performance channel in Slack.

#core-performance, #performance, #performance-chat, #summary

Connect with the GitHub Outreach group to request feedback or further testing. 

During the Hallway Hangout: What’s next to the outreach program, the idea came up to create a GitHub group called “outreach” that can be pinged when a PR, a discussion, or an issue needs some further input from the outreach group. Sometimes developer or designers would like a few more voices to chime in on an issue, a solution or on a new feature. Or they are ready to have more people test a PR or a new feature. Now there is a group of contributors you can pingPing The act of sending a very small amount of data to an end point. Ping is used in computer science to illicit a response from a target server to test it’s connection. Ping is also a term used by Slack users to @ someone or send them a direct message (DM). Users might say something along the lines of “Ping me when the meeting starts.” to alert them to your work.

It works from any GitHubGitHub GitHub is a website that offers online implementation of git repositories that can easily be shared, copied and modified by other developers. Public repositories are free to host, private repositories require a paid subscription. GitHub introduced the concept of the ‘pull request’ where code changes done in branches by contributors can be reviewed and discussed before being merged be the repository owner. https://github.com/ Repo in the WordPress organization 

For now, its active contributors are listed, but it’s open to anyone who would like to be alerted when developers on the WordPress project request additional feedback or testing. The only requirement is to have a GitHub account. 

For developers or designers 

Ping @WordPress/outreach

PRs can be work in progress or already merged. For merged ones that are part of a set of PRs for a feature, we might also create a call for testing for a broader reach in collaboration with the #core-test team.

Ideally, a ping should point to a set of testing instructions, maybe additional questions and a time frame in which the feedback would be expected.  

If there are discussion posts on the GitHub’s repo that need to be amplified, a ping certainly is welcome here too. 

Depending on the PR/feature the ping could also be used to request a call for testing that we collaborate on with the Test team, that goes out to more users

For contributors:

If you want to participate in a request for feedback, please contact @bph or @fabian to be added to the group. Or just post in the #outreach channel, that you would like to join.

Props to @fabiankaegy and @greenshady for review

#github, #test