Live data from Hacker News

From Bootstrap to CSS Grid

open.nytimes.com

31–40 of 104 posts

Re: From Bootstrap to CSS Grid

#34
post #28

Can someone illuminate me as to what are some of the reasons that would make someone style with CSS Grid with a Fallback to Bootstrap? Considering you are already writing Bootstrap due to compatibility concerns why not just keep using that? I feel like adding another dependency like this would just create a risk of having design differences pop up over time. Mind you, I don't hate CSS Grid. I really enjoyed learning…

> Can someone illuminate me as to what are some of the reasons that would make someone style with CSS Grid with a Fallback to Bootstrap?

Generous interpretation: graceful upgrade when CSS grid has sufficient browser support.

Realistic interpretation: to work with the 'new hot' and not the 'old stodgy'

Re: From Bootstrap to CSS Grid

#36
So I love CSS Grid very much, but have found myself still wanting/needing masonry-style "Pinterest" layouts, which I haven't been able to do without JavaScript. I've seen many of the CSS column and flexbox hacks, but nothing quite nails it.

Anyone have any good ideas here?

Re: From Bootstrap to CSS Grid

#37
It's interesting to now have this, flexbox, and the multi-column module (that I never see anyone talking about).

Does anyone know if this can be used for dynamically wrapping columns? Ostensibly flexbox should be able to handle that, but without an explicit height your column will never wrap.

I recently needed to implement dynamically wrapping columns and I was able to get 90% of what I needed from the multi column module. However it seems to be really buggy at this point, it often ended up with elements sliced in half or missing. Also, the biggest issue for me was no way to target the columns and prevent reordering. I had sections of text that could be expanded or collapsed, and that would trigger a complete rearrangement of columns. Nasty.

I ended up coding my own column system for vertical wrapping, and it was so helpful I was thinking about open-sourcing it, but I'm not sure if CSS grid obviates the need.

Re: From Bootstrap to CSS Grid

#38

What are the preferred solutions for people that are forced to support IE11? I've seen fallback CSS and JavaScript polyfills used.

Was wondering the same thing. I wonder if postcss and autoprefixer supports it? https://github.com/postcss/autoprefixer/issues/603

This comment is from two years ago:

But I think I found a solution for everyone:

We support Grid by default. If Autoprefixer see that your CSS is too complicated for IE, it will warn you to disable Grid support and use some JS polyfill.

Re: From Bootstrap to CSS Grid

#39
CSS Grid blew me away the first time I saw it. I didn't realize it was ready on the latest browsers. I switched from bootstrap recently to tachyons, this is just another reason to not miss it.
Post reply on HN