Reusable Blocks Renamed to Patterns with Synced and Non-Synced Options

There has always been some confusion and overlap between reusable blocks and patterns. The difference was that reusable blocks can be created and edited in the block editor and then reused in other places – inserted into posts or pages. Block patterns, once inserted, can be edited and are not synced. They give users the ability to apply the same layout to different posts and pages.

Reusable blocks have now been renamed to patterns, with the option to be synced, which offers the same functionality as the former reusable blocks where all instances can be updated at once. Non-synced patterns are just regular patterns – those that can be edited independently of other other instances that have been inserted. These updates are coming in Gutenberg 16.1 and will be included in the upcoming WordPress 6.3 release.

WordPress contributor Aki Hamano posted a diagram to Twitter regarding the renaming, which was confirmed as an accurate representation of the changes.

“Clients already find the pattern and reusable block concept very difficult to grasp,” WordPress developer Mark Howells-Mead commented on the pull request for the renaming. “This change will make things much harder for regular users to comprehend.”

Gutenberg contributor Paal Joachim Romdahl commented that it would be helpful to have more time to test this in a few versions of the Gutenberg plugin, as WordPress 6.3 beta 1 is expected this week. Learning materials and documentation will need to be updated with very little notice.

Gutenberg contributor Daniel Richards encouraged contributors to see the change as part of “the great unification,” an effort towards consolidating the many different block types into a single concept and streamlining the content and site editors.

“In the future it might also be possible for template parts to be considered ‘synced patterns’, and at that point things become much more streamlined and there are far fewer concepts for users to grasp,” Gutenberg contributor Daniel Richards said.

“So the hope is that this is a first step on the path to making things easier for users, rather than more difficult. But I do realize that for existing users it’s quite a shift.”

As part of this effort, WordPress 6.3 will also introduce pattern creation in the block editor using the same interface that it previously used for reusable blocks. Pattern creation necessitates having a place for users to view and manage their patterns. WordPress 6.3 will also include a first pass at a Pattern Library inside the Site Editor, which will include both patterns and template parts. Gutenberg designers shared a preview of what this would look like a couple weeks ago:

image credit: WordPress Design Share June 5-16

The Potential of Partially Synced Patterns

In May, contributors began a discussion about the concept of partially synced patterns, which Daniel Richards summarized:

Today, when you insert a pattern, the blocks from that pattern are completely decoupled and standalone. There’s no way to tell that those blocks originated from a pattern, especially since they can be edited to no longer resemble the source pattern.

Partially synced mode is different. When a pattern that’s partially synced is inserted, it retains a reference to the source pattern. The blocks within the pattern are locked so that they cannot be removed or reordered and new blocks cannot be inserted (this is called contentOnly locking). Only specific parts of the pattern considered ‘content’ can be edited (denoted by adding __experimentalRole: 'content' to a block’s definition).

When the source pattern is updated, all instances of blocks that reference the source pattern are updated too (much like a reusable block), but the content values the user entered are retained. The best way to think of this is that the user can update the design of a pattern, but doesn’t lose content that exists in templates and posts.

This concept will not make it into the upcoming version of WordPress, as contributors are still discussing one of many complex implementations, but it offers a glimpse of what might be more granular control coming to patterns in the future. Partially synced patterns would bring distinct benefits to many CMS and content design use cases where clients may be editing content.

“I am a site developer for an agency, and am actively making sites for clients using Gutenberg every day,” Eric Michel said. “Probably our biggest pain point right now is that the editor does not handle types of content that are mostly standardized with small content customizations per post – things like contact directories, majors at a university, products in a catalog.

“For us, the absolute dream scenario is what you are proposing, except with the inclusion of the ability to alter the primary template and have all of the pages that use that template automatically change as well.”

The discussion on making partially synced patterns possible continues in search of an implementation that will ensure users don’t modify the patterns in ways that destroy the ability to display the retained content. WordPress 6.3 will ship with synced and non-synced pattern options, and partially synced patterns may land further down the road in a future release.

9

9 responses to “Reusable Blocks Renamed to Patterns with Synced and Non-Synced Options”

  1. This is both intriguing and maddening, and for the same reason: it should have been this way all along. As a developer, it’s both something I’ve desperately needed for my clients but also one more step in making me want to abandon WordPress as my professional tool of choice, both practically — because the ground constantly shifting beneath my feet makes it hard to trust the tool — and philosophically — because it’s increasingly obvious that the core team has little regard for the needs of professionals like me, who are held back by the limitations of Gutenberg, even while my end-user clients are completely bewildered by it. I keep asking myself who is this actually for, and I don’t think anyone can really give an answer that holds water.

  2. Classed based styling of a pattern would be nice. Eg, instead of the current inline styling of, say, all 20 persons on a team page, we would style the “team-member” pattern class in the site editor or whatever.

    I second Eric’s comment, the current implementation of styling patterns is a huge pain point.

    Currently, I’m moving all styling of patterns to a separate stylesheet.

    Is there a better way?

  3. I would be more confused than I was ever before. Is there any way existing users will be notified about the changes on their WordPress dashboard? Like ” Your reusable blocks have been renamed as patterns and will be available under patterns.”

    Please enlighten me if I am missing something here. Thanks!

  4. Even I don’t know what template parts are, I think WordPress really needs ax great overhaul and simplifying of the whole panel and names. Right now the site editor and its terminologies are like a separate alien from the whole dashboard.

  5. Too many cooks, too many ideas, no central planning, changing metaphors and duplicating concepts “on the fly”. These are all symptoms of a loss of leadership from the top down that have left us floundering for over three years with these types of things.

    The politics of how these decisions are made is also troubling, because the folks who make them do not seem to be actively in the business of using the software to service live customers….likely because of the move to React and all the complexity that requires “advanced” developer skills to contribute in these matters vs. previous php/html/css/js.

    With non-consumer facing developers, left to create and change the mechanics without a top-down management from experienced marketers/Ui testers, while the rest of us are trying to build solutions for paying civilian customers… there is this. Someone has changed the position of the gas pedal, the clutch and the brake pedal while we are all driving the car.

    Solution? Put a HALT to any dramatic changes such as this until or unless the actual community has an opportunity, in a public way (not via the closed and rather snarky development boards)…to react to and comment on how such changes would be useful/helpful or harmful.

  6. Personally, I never understood why a niche feature such as reusable blocks was introduced so early in Gutenberg history while other more pressing issues were left unsolved for so long or are still unfixed as of today.

  7. When I moved to blocks, I created what was called a reusable block and didn’t know until I tried to change one on a page that it would change all the instances of that block. So basically I wanted to use patterns that then came along shortly after that.

    I see the logic – something that you create for pages and posts that you can reuse for each is a “pattern”. Now you will be able to sync them or not depending on the application.

  8. I feel that the only thing that needed to happen was leave Reusable Blocks alone, and let them be syncronous across the board wherever you put them, and in the block selector, just add a tab where the Reusable Blocks can be selected. As it currently stands you have to go through hoops to find your Reusable Blocks, unless you have saved the url to that section of your dashboard, and some better navigation could be provided. Let the patterns exist as elements that can be edited individually. I just Reusable Blocks as a blog post “footer” so that I can have syncronized content across my entire website, and it is very beneficial to have one Reusable Block I can edit, and then essentially update the entire website with one click. I don’t need Reusable Blocks that can be changed here and there. That would be too confusing.

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.

Newsletter

Subscribe Via Email

Enter your email address to subscribe to this blog and receive notifications of new posts by email.

Discover more from WP Tavern

Subscribe now to keep reading and get access to the full archive.

Continue reading