How to dynamically generate images with Node.js

🚫 Problem Having to manually 😴 create unique images for Social Media (Open Graph) for your new blog posts. ✅ Solution Let’s use Node.js to engineer a script to take care of this for us 😎 ❤️ Generated image This is the final result, a dynamically generated image: 🤔 How does this work? A part […]

Defer CSS loading with WordPress

So you’re learning about Critical Rendering Path, you have already optimized your WordPress theme’s stylesheet but still there are WordPress core CSS files that you want to lazy load. I have a present for you 🎁 One of several techniques is to load the stylesheet using media=”print” which tells the browser this file is meant […]

How to defer scripts in WordPress

You don’t need me explaining you how important it is to defer scripts for performance. If your application doesn’t need render-blocking scripts you should simply defer them. Most of the WordPress blogs/sites do not need render blocking scripts, for toggling menu visibility, swapping emojis for SVG’s, embed media… All these can be deferred no problem. […]

Creating a Link Manager with WordPress

You know I’m a huge WordPress fan and I rely on it whenever I need a CMS. At this point pretty much everything is possible, don’t want to mess with PHP? Sure, use it headless with GraphQL and Next.js or the provided out of the REST API. Today I won’t be using any of the […]

How to add a class to Tag Cloud items – WordPress

If you want to extend the WordPress Tag Cloud Widget with your own custom CSS class, you can easily use the wp_generate_tag_cloud_data filter like so: Docs: filter: wp_generate_tag_cloud_data wp_generate_tag_cloud()

How to add custom meta data to WordPress REST API

The WordPress REST API is a very neat thing. I’m using it to pull my To-Do list into my Firefox Start Page, which I find totally awesome 🤩 If you’re using custom post meta data is not as straight forward. For some reason the meta data is not exposed by default when you query posts […]

Creating a To Do list WordPress theme

You might not know this about me but I used to be a WordPress developer, I used to get paid to exclusively develop Themes and Plugins at the company I worked for. It has been a while and I’ve lost the edge when it comes best practices and latest news. Specially around PHP and MySQL. […]

Behold my new domain name! 🤩

First of all, we need to travel back to 2019, when Google launched a new top-level domain. 👨🏻‍💻 .dev Before making it publicly available Google decided to have an auction period, in which people could bid on a name. Which makes perfect sense for brands. My idea was to get ricard.dev but was not willing […]

WordPress in sub-directory with NGINX

If you want to have a WordPress installation inside a sub-folder. Maybe you have a WordPress inside a WordPress, sounds more complicated that what it actually is. You might get an error when trying to publish a post or page: The response is not a valid JSON response. The scenario could be like this: Example.com […]