Hacker News new | ask | show | jobs
by msoad 3061 days ago
I worked with CSS Grids back in 2010 when I was working on a Windows 8 app. Since then I hated any other constraint resolver including Box Model, iOS Auto Layout and Flexbox model.

CSS Grid is so intuitive you forget how difficult this problem has been in the history of UI engineering

1 comments

The intuitiveness of CSS Grid is the major appeal for me.

I've worked with Flexbox for the last few years and still regularly have to look up the Flexbox reference pages. Perhaps it's just me, but I have found the whole Flexbox naming scheme anything but intuitive.

I haven't built a site in the last 5 years without flexbox and not a single time was I able to interact with it without referring to docs, then still randomly iterating through property values in the inspector until it looked right. That's basically my official process. Luckily the problem space is simple enough for that to be efficient, and only a couple of properties are needed 90% of the time.
I've had the opposite experience. I haven't floated anything in years, and I'm constantly running into problems that I can quickly solve using simple combinations of flexbox, margin, and padding.

For the first year or so, I often had to look at this cheat sheet: (https://css-tricks.com/snippets/css/a-guide-to-flexbox/, but now it all feels very intuitive.

The one exception is `align-items: stretch` never works how I expect it to, and I usually end up with a combination of `flex-basis 100%` or `max-width: some px value` with `width: 100%;`