
Copy-paste snippets for blocks, block themes, security, performance, Tailwind CSS, PHP and React. New snippets every Monday, Wednesday and Friday, each one run in a real WordPress before it is published.

Turn off the Gutenberg block editor for chosen post types in WordPress and use the classic editor for them, while posts and pages keep blocks.

Disable WordPress native lazy loading for images and iframes with one filter, or limit it to post content when only some images are affected.

Stop the WordPress emails sent after successful automatic core, plugin and theme updates, but still get an email when an update fails.

Stop posts from being published until a category and one of its subcategories are checked. Save Draft keeps working, and the editor shows the error.

Why get_transient() keeps missing in WordPress and your expensive code runs on every load, plus a helper that caches false, empty and long-keyed values.

A custom WP-CLI command that reads every admin account straight from the database and flags admins hidden from the Users screen.

Add an Export CSV button to any WordPress post type list screen, with nonce and capability checks, terms, meta and formula-injection protection.

Register a WordPress Block Bindings source that fills core Paragraph, Heading and Button blocks with a post’s last-updated date and author.

Add categories and tags to WordPress pages and list those pages in the category and tag archives, next to your posts.

Files structure The project is organized with a very simple file structure. At the root, there is a build.js file which is the script that runs esbuild and compiles both the JavaScript and SCSS into production-ready code. The dist folder is where the compiled files end up — inside you’ll find main.min.js for the bundled…

github yaml location This will push code to NPM after you craete tag with v Example: v1.0.1 NPM_AUTH_TOKEN esbuild.js package.json example

Instead of adding one by one you can include all files inside /inc/ folder If you need to load only php files

CSS Needs minimum selector Load CSS in Editor Load CSS in Theme (Front End)

Save large WordPress image sizes at quality 100 and keep thumbnails at the default 82, with the wp_editor_set_quality filter.
3rd party plugins actions admin archive block-themes block editor Blocks block theme build capabilities core CSS Custom Post custom post types Developer development filters full site editing gutenberg hook hooks Image img load styles maintenance media mu-plugin Must Have npm Oxygen performance php plugins rest api scripts organizer security single product theme.json Tips updates users WooCommerce wordpress wp-cli WP Admin