Get the latest tech news
A gentle introduction to anchor positioning
Anchor positioning allows you to place an element on the page based on where another element is.
The position-area allows you to place your element on a nine-square grid where the anchor takes the center spot. The positioning you set for your menu works on desktop, where you’re got plenty of space on the right for the element to spill over, but what about on mobile where your viewport is more narrow? Thinking of anchor positioning as a grid that you place things on can be a helpful and intuitive way of writing your code.
Or read this on Hacker News