Caching issues with theme.json

While developing a WordPress Block theme, if you’re struggling to see your changes reflected on the site, consider adding this constant on your wp-config.php:

define( 'WP_DEVELOPMENT_MODE', 'theme' );

This constant was introduced with WordPress 6.3, around mid-2023. Other values you can use are core, plugin, or all.

Setting the theme value will indicate WordPress to bypass the cache generated for that theme currently in development.

Just be sure that it doesn’t get pushed to production.

More info: https://make.wordpress.org/core/2023/07/14/configuring-development-mode-in-6-3/

Leave a Reply

Discover more from Esteban Cairol

Subscribe now to keep reading and get access to the full archive.

Continue reading