Tag theme
How To Register A Custom Post Type In WordPress
A custom post type, or CPT, is a new type of content besides posts and pages, such as portfolio items, products, events or testimonials. Register it with register_post_type() on the…
How To Display Post Thumbnails Correctly In WordPress
Featured images, also called post thumbnails, need theme support first. After that, use has_post_thumbnail() to check if the post has an image and the_post_thumbnail() to print it.
How To Use Css @Scope To Limit Styles To A Component
The @scope rule applies styles only inside a specific part of the page. It gives you component-level styling without BEM naming, CSS Modules or deeply nested selectors.
Essential WordPress Css Classes Every Theme Should Style
WordPress adds a set of classes to content, images and editor blocks. A good theme styles them, otherwise alignment, captions and accessibility features can break.
How To Use Css @Layer To Control Specificity And Cascade Order
Cascade layers let you decide which group of styles wins, no matter how specific the selectors are. A rule in a later layer beats a rule in an earlier layer,…


