WordPress Contributors Discuss Launching an Official Block Pattern Directory

Block patterns were one of the most exciting and transformative features introduced in WordPress. 5.5, giving users a giant head start on building pages by allowing them to insert sets of pre-designed blocks. Core now includes a handful of default patterns available in the block inserter but contributors are exploring the idea of expanding this small selection into a full-blown pattern directory.

Alex Shiels opened a discussion on make.wordpress.org to get feedback on how it might be implemented. He suggested that the pattern directory would be similar to the block directory, minus the need to install plugins in the background. Community-contributed patterns could be searched and added via one-click installation from the block inserter.

Shiels asked for feedback on several questions, such as how block patterns could be represented in search results and how previews could accurately reflect how a pattern might appear with different themes. One of the most important considerations he raised: Should the Block Pattern Directory be limited to patterns using only core blocks?

If patterns can only contain core blocks, that leaves it to third-party markets to provide patterns that include blocks from plugins. It seems more likely that block plugin developers would opt to ship their own selection of patterns inside their plugins, instead of contributing to the pattern directory. Having it open to all blocks hosted in the directory would encourage a more diverse range of patterns. Patterns requiring a non-core block might include a prompt to download it.

The WordPress community has already created many different unofficial pattern libraries, although the terminology can be confusing. Gutenberg Hub’s template library may be one of the most prominent. It provides section patterns and full page templates that users can browse and then copy the code to paste into their own sites. Jeffrey Carandang’s “Share-a-Block” site also offers a selection of patterns to download.

WordPress.com has just launched its own pattern library today with more than 100 patterns pre-designed patterns available. Automattic plans to add more patterns based on user feedback and requests. This new free library will make site building easier for millions of users and also creates a strong incentive for using the block editor.

Patterns leverage all the best things about the new editor. Inserting a pattern is easier than wrangling shortcodes or wading through theme options to try to get the right combination to reproduce the demo. Patterns are more approachable than page builders and don’t require learning a new interface.

As the momentum around block patterns increases, I think we will see more commercial theme and block plugin creators using patterns to showcase their products and provide starter packs. It is the best way to help users understand the wide range of possibilities that the block editor enables.

Having an official directory of community-contributed patterns could be an interesting way for creators to cross-promote their free blocks and designs, while opening up a whole new world of design options for self-hosted WordPress users. How many times have you been shopping around for just the right WordPress theme and found that you like certain sections and layouts offered in several different themes? Patterns give you the ability to cherry pick different sections to create your own unique layout for each page/post, without having to wrestle with the limitations of your theme.

The ability to browse and access community-contributed patterns directly within the editing interface may have a long list of technical challenges to solve, but it would undoubtedly put more design power into users’ hands.

Not everyone can take a blank canvas and artfully combine blocks to produce sophisticated designs. Putting patterns at users’ fingertips would make site building more of a delight, especially for users who are new to the block editor. It might also allow users to save their favorite patterns for future use, in the same way you can save your favorite themes and plugins.

The discussion on WordPress.org is just getting underway. A few of the original contributors on the idea have created a GitHub repository to track and explore some of the more technical considerations of launching an official block patterns directory. If you have ideas to contribute on how this could be implemented or want to share other considerations, make sure to comment on the post.