Receive my new posts and videos in your inbox, along with some links and thoughts from the web dev world. No more than once a month. Browse the archive.
Extending WordPress blocks to talk to each other means using the WordPress Core Data packages, and hidden block features like “context”. With tools like useSelect and useDispatch, we’ll add a button to a core block that inserts new blocks into it’s parent block.
What are Application Passwords in WordPress and how can I use them? Let’s dig into the WP REST API and how you can make authenticated API calls from tools like Postman (and any other code base) by using core WordPress’s Application Passwords feature.
Let’s build a dynamic block for WordPress. Along the way we’ll discuss the difference between static and dynamic blocks, when to use them, WP_Query, what ServerSideRender is and what the best approach for performance is.
How to approach migrating your permalink structure to remove the date directories (ex: /2023/01/01/).
Using just three filters, we’ll add a few custom fields to the core “Button” block in WordPress that will update the button’s content on the front end.
How to offer a selection of page patterns when creating a new page (as seen in TwentyTwentyFour).
Dynamically populate social link URLs using the render_block filter in WordPress.
If you’re managing an older website running Font Awesome 4, you might be asked to swap out the Twitter icon for the new X / 𝕏 symbol. Personally, I wasn’t in the mood to pull down an entire site, dig up the build process, replace FA4 with a newer version, etc. Instead, I jumped into…
A great way to start building blocks for WordPress is using InnerBlocks. Group other blocks together and easily add styles and settings.