Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The first "trap" on the page says "min-width: auto makes min width determined by content", but this is false outside of flex/grid.

From MDN: "For block boxes, inline boxes, inline blocks, and all table layout boxes auto resolves to 0."

https://developer.mozilla.org/en-US/docs/Web/CSS/min-width



I guess the first trap should really be: "You cannot read any CSS property in isolation, as just like what the name implies, defaults and what values end up doing cascades through all the rules your document ends up using"


CSS cascade for text properties more or less makes sense.

I have been unable to comprehend CSS layout from any perspective: page designer, implementer, user, anything. It must have someone in mind but I have no idea who I that is.


https://every-layout.dev has by far the best explanations and coherent usage of CSS I've encountered since I started doing webdev for a living in 1998.


Every Layout changed how I look at and do CSS. Great resource with a good philosophy behind it: CubeCSS. It really made CSS fun for me again.


Layout is more bazaar than cathedral. It has had many ideas mixed in by different contributors over decades.


Thanks I will correct that




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: