You can now add your own plugins to the Block Directory


Introducing the Block Directory in WordPress 5.5

The WordPress 5.5 Beta release that’s now in testing includes Block Directory support enabled by default. In case you missed it, the Block Directory is a subset of plugins in the plugin directory that can be instantly and seamlessly installed from the Gutenberg editor with a single click. We call these new plugins “block plugins” and have worked hard to make it easier for people to contribute to this new feature coming to WordPress 5.5. This post is meant to help show how to get your very own block plugin added to the directory and share some helpful resources along the way.

Step 1: Create your own block plugin

If you haven’t yet had a chance to create a Block Plugin, don’t fear! There’s still some time until the August 5.5 release. Here’s a new and improved tutorial that walks you through the process of creating a block plugin. More documentation is on its way too and you can join the discussion about what would be helpful to have shared in this GitHub overview issue.

The guidelines for Block Plugins are still in the process of being finalized. Block Plugins need to be much more minimal than a regular WordPress plugin in order to be safely installed with a single click. That means as well as keeping to the regular plugin guidelines you’ll also need to follow some additional rules. In particular, you should stick to mostly JavaScript code and keep PHP to the bare minimum; and not add any UI or other code outside of the Gutenberg editor.

Step 2: Run your block plugin through the checker tool

In order to help developers follow the guidelines and best practices, we’ve been working on some documentation and a new tool. It’s called the Block Plugin Checker. Give it a plugin repo URL, and it will examine the code to look for possible problems to resolve before your block plugin can be added to the directory:

This is still a work in progress so if you find any fun bugs or omissions, please let us know. We’d love the chance to fix them and to make the Checker a more useful tool.

Step 3: Add your block plugin directly to the Block Directory

If you’re a committer of a block plugin that does meet the criteria for adding it to the Block Directory as confirmed by the Checker tool, you can then add it yourself using the same tool:

Likewise you can remove it at any time using that same tool if you notice problems or would prefer it wasn’t included. 

Going Forward

We’ll be making improvements to the Block Plugin Checker, and doing additional testing of plugins that are added, so please expect some changes along the way. If you have any feedback or questions, please comment here or in #meta on Slack.

#features #block-directory