Using Block Patterns as content templates

Block patterns are great, one of the features I’m most excited for in WordPress. As block patterns mature and people adopt, they will be one of the best ways to share designs and templates. I’m looking forward to a rich repository to pull design ideas, the pattern directory is already filling up. Block patterns aren’t […]

Gutenberg and WordPress Core

I recently had the need to update Gutenberg packages that are in WordPress core for a point release. This required setting up a development environment where I can test Gutenberg code in WordPress but without using the Gutenberg plugin. This is not something most developers will need to do, it is my first time after […]

Make your own create-block templates

Did you know the create-block script can support templates? With templates you can create your own files to be generated for a new block. I see this being quite useful especially if you are an agency or business that creates many custom blocks, or for developers to share different block starting points. What is the […]

Conditionally Load Block Assets, Part 3

In WordPress 5.8, releasing on July 20, there is a much easier way to conditionally load block assets. This is the loading of JavaScript and/or stylesheets on the frontend only if the block is shown on the page. I wrote twice previously about solving this same problem. The first time, I solved checking if each […]

Contribute Developer Documentation to Gutenberg

Another post in my series on contributing to the WordPress Gutenberg project. This post complements my Good First Issue post that focused more on a coding contribution. Here I take a step back and focus on documentation and dive deeper into the GitHub pull request process. Find an Issue Browse the Documentation label on GitHub […]

Conditionally Load Block Assets, Part 2

Another look at conditionally loading block assets for WordPress blocks, assets being JavaScript and CSS files loaded by the browser. In the previous post, I solved using heavy-handed testing of each post in the loop checking to see if it contains our block to load the assets. The company I work for runs a few […]

Conditionally Load Block Assets

Updated: see Part 2 post that explains a better way, as pointed out in the comments. Or see the newer Part 3 post with an even easier way with WP 5.8. One of the great features of the WordPress Block Editor is all the specialty blocks that can be created. This can also be the […]

Build a Block Series – Part 7: Placeholder

In this seventh part, I do away with screencasting and work on improving the editor interaction with the QRCode block. Specifically, showing in the editor how the QRCode will look when published. Previous screencasts: Development Environment WordPress Plugin Anatomy of a Block Block Attributes ES6+ Syntax QRCode Intro One of the primary tenets of Gutenberg […]

Build a Block Series – Part 6: QRCode

In this sixth screencast I get down to implementing the QRCode part of the block: loading the qrcode.js library and trigger it using the saved URL to create a QRCode. Previous screencasts: Development Environment WordPress Plugin Anatomy of a Block Block Attributes ES6+ Syntax QRCode Implementation In the cast, I alter the block’s save function […]

Build a Block Series – Part 5: ES6+ Syntax

The fifth part of my series walking through building a Gutenberg block for the WordPress editor. This part takes a break from new block development to explain some features of ES6+ syntax used, specifically Destructuring assignments, Arrow functions, and Imports. Previous screencasts: Part 1: Development Environment Part 2: WordPress Plugin Part 3: Anatomy of a […]