Proximity Scope (@scope in CSS) | Tutorial from Chris Coyier @MasterDotDev
Proximity Scope (@scope in CSS) | Tutorial from Chris Coyier  @MasterDotDev
Uploaded March 2026 | Updated November 2026, 3 hours ago
Proximity scope is a feature of `@scope` in CSS. While resolving a selector within an `@scope () {}` at-rule, selectors with the same specificity will rely on DOM proximity to decide a winner above what would have otherwise been source order. This is a whole new step in the cascade for CSS. It’s a bit niche of a concern, but it actually can make CSS work more intuitively, fixing an issue where an obviously closer class is losing to another class just because of the order they appear in the CSS.

Proximity Scope Basic Demo: codepen.io/editor/chriscoyier/pen/ZYGdBje
Limit the reach of your selectors (blog post): developer.chrome.com/docs/css-ui/at-scope Scope in CSS Blog Post: frontendmasters.com/blog/scope-in-css
Nicole Sullivan’s Blog Post: stubbornella.org/2011/10/08/scope-donuts
Donut Scope Tutorial: frontendmasters.com/tutorials/chris-coyier/donut-scope
DOM Blasters Tutorial: frontendmasters.com/tutorials/chris-coyier/dom-blasters

Find Frontend Masters Online:
Twitter: twitter.com/FrontendMasters
LinkedIn: linkedin.com/company/frontend-masters
Facebook: facebook.com/FrontendMasters
Instagram: instagram.com/FrontendMasters
TikTok: tiktok.com/@frontendmasters

About Us:
Advance your skills with in-depth, modern front-end engineering courses — our 250+ high-quality courses and 24 curated learning paths will guide you from mid-level to senior developer! Start your path to mastery today: frontendmasters.com/?utm_source=youtube&utm_medium=home_link&utm_campaign=exlusive
Proximity Scope (@scope in CSS) | Tutorial from Chris CoyierAI is just APIs, not magic ✨Fully Typed Client APIs with OpenAPI Schema 🛠️Accessibility tip: Use a Svelte attachment `{@attach}` to keep keyboard focus inside your modal.Adapting to the AI Revolution in Development 🚀RAG isnt magic 🪄 Its math 🧮We still need humans in the loopYou Have Way More Control Over Claude Code Skills Than You ThinkSimplify Promise Handling in Vite with Eager Loading ⚙️VSCode Can Do Anything… But Can It Run Doom? 💀Software Engineer on the GitHub Copilot team, Sabrina Goldfarb | Episode 27Full-screen, Animated Navigation Menu | Tutorial from Kevin Powell
MasterDotDev |

Proximity Scope (@scope in CSS) | Tutorial from Chris Coyier

SHARE TO X SHARE TO REDDIT SHARE TO FACEBOOK WALLPAPER