When you create a block in the WordPress Block Editor (Gutenberg) you can create an area that allows other block types to be nested inside your block. You do this with the InnerBlocks component. In our other guides we previously…
Register a Block Template for the WordPress Block Editor (Gutenberg)

In my previous guide I explored the power of block patterns. Block templates are similar, but instead of relying on your client to insert block patterns into the editor, it gives them a full layout as soon as they insert…
Register a Block Pattern in the WordPress Block Editor (Gutenberg)
![register_block_pattern( 'wholesomecode/example-block-pattern', [ 'categories' => [ 'my-client', ], 'content' => $block_pattern_content, 'description' => 'An example block pattern', 'keywords' => 'example', 'title' => 'Example Block Pattern', 'viewportWidth' => 800, ], );](https://wholesomecode.ltd/wp-content/uploads/2021/03/Register-a-Block-Pattern-in-the-WordPress-Block-Editor-Gutenberg.png)
Block patterns in the WordPress block editor (Gutenberg) are a powerful feature that let you create varied layouts with very little effort. Using register_block_pattern you can very quickly create a block pattern for you or your clients. You build block…
Creating a Plugin for the WordPress Block Editor (Gutenberg)

If you are new to the WordPress Block Editor (Gutenberg) you may be wondering how to get started with creating your own plugin. Luckily the WordPress development team have a handy npm script for you to create a block plugin…
Install WordPress Repository Plugins and Themes with Composer
![{ "name": "wholesomecode/composer-example", "description": "Demonstration of how to use composer within WordPress", "require": { "wpackagist-plugin/wholesome-publishing":">=1.3.0" }, "repositories": [ { "type":"composer", "url":"https://wpackagist.org" } ] }](https://wholesomecode.ltd/wp-content/uploads/2021/02/Install-WordPress-Repository-Plugins-and-Themes-with-Composer.png)
In my last guide I told you how to install your GitHub maintained WordPress themes and plugins with composer. Well what if I told you you could also use composer to install any Theme or Plugin from the WordPress repository?…
Install WordPress Plugins and Themes from GitHub with Composer

In your client projects, do you keep installing the same theme or plugin that you have developed? Do you make a fix in one project that you really wish you could easily roll out to all the other projects? If…
update_post_meta WordPress Block Editor (Gutenberg) Equivalent is editPost

If you are wondering how to update_post_meta on the current post with Gutenberg, this is the article for you. You can just use editPost like so: The code above will update the post meta wholesomecode_meta_key_example with the value ‘Example’. Remember…
wp_get_attachment_image WordPress Block Editor (Gutenberg) Equivalent is getMeta

Looking for how to get the post thumbnail, or an attachment URL by its Id in WordPress gutenberg? You may have a returned post object by using the WordPress Gutenberg equivalent of WP_Query (or the WordPress Gutenberg equivalent of get_post)….
get_post_meta WordPress Block Editor (Gutenberg) Equivalent is getEditedPostAttribute(‘meta’)

If you are new to writing plugins for the WordPress Block Editor (Gutenberg), you may be searching around for how to get the meta of the current post with get_post_meta. Never fear, you can still get_post_meta, just use getEditedPostAttribute(‘meta’) on…
WP_Query WordPress Block Editor (Gutenberg) Equivalent is getEntityRecords

If you are new to writing plugins for the WordPress Block Editor (Gutenberg), you may be a little confused how to do all the things you did regularly, like grabbing posts with WP_Query. You will be very pleased to know…