News for hackers. Stuff that matters.
Re:CSS grid garden by superkuh on Monday December 24, 2018 @01:42PM (#18753550)
There's no mainstream browser that doesn't suck (ie, they're all walled gardens) that supports CSS grid. Plus the other 4 billion people on Earth not in modern countries.
Re:CSS grid garden by androidgirl on Monday December 24, 2018 @01:55PM (#18753628)
Use CSS grid with Flexbox for fallback.

I create my mobile version of pages with Flexbox, so if the user's browser doesn't support it, they see the full featured mobile view. Progressive enhancement.

Re:CSS grid garden by zamalek on Monday December 24, 2018 @04:01PM (#18754253)
Curious how you manage this. Do you use feature detection and then apply a class to <body>?
Re:CSS grid garden by fgkramer on Monday December 24, 2018 @05:20PM (#18754600)
Not OP, but it is usually done by using support tags:

https://developer.mozilla.org/en-US/docs/Web/CSS/@supports

You'd write two versions, one for browsers which do support grid and one for the ones which don't.

Jen Simmons has written excellent tutorials on doing fallbacks and explaining how we can use css grids nowadays: https://hacks.mozilla.org/2016/08/using-feature-queries-in-c...

And also has a YouTube channel where she explains a lot on how to deal with css grid in the wild: https://www.youtube.com/channel/UC7TizprGknbDalbHplROtag

Re:CSS grid garden by androidgirl on Monday December 24, 2018 @07:15PM (#18755035)
I build all my mobile layouts with flexbox, so they are usually one long column, and content collapses into the grid from CSS media queries.

If the browser doesn't support css grid, the mobile, single column version with flexbox is fully featured, and is loaded first because the css grid is kept in @media queries.

Like the sibling comment mentioned, you can use @supports, however if you use `display: flex` for mobile and `display: grid` for desktop, the grid will never load in old browsers anyways.

This works out pretty well for me personally in 99% of use cases. If you want to use CSS grid as well for mobile, you'll need a more powerful @supports solution, however.

Re:CSS grid garden by bgorman on Monday December 24, 2018 @02:56PM (#18753943)
IIRC, Safari, Edge, Firefox and Chrome all support CSS grid.
Re:CSS grid garden by warent on Monday December 24, 2018 @01:44PM (#18753565)
Firefox supports it. You're aware Firefox is OSS right?
Re:CSS grid garden by superkuh on Monday December 24, 2018 @01:45PM (#18753574)
Firefox went walled garden in v37.

That said, at least this css grid garden has a elegant fallback. Most CSS grid sites don't. Or worse, they fall back to 'mobile' sites.

Re:CSS grid garden by kenbellows on Monday December 24, 2018 @01:47PM (#18753587)
"Walled garden" in what sense?
Re:CSS grid garden by superkuh on Monday December 24, 2018 @01:51PM (#18753610)
The walled garden I speak of is the implementation of add-ons cryptographically signed by Mozilla only. Unless you run one of the betas (w/bugs) you cannot use any add-on not approved by Mozilla. And lately they've even been removing/banning add-ons that aren't illegal but otherwise upset outside corporations (ie, the paywall bypasser that uses googlebot's http headers substituted in).
Re:CSS grid garden by Digital-Citizen on Monday December 24, 2018 @08:59PM (#18755411)
It's important not to lump together the proprietary browsers (where the limit you speak of can only be worked around if the proprietors allow) and free software browsers which respect your software freedom, like Firefox.

You could modify Firefox source code to let you run whatever add-on you wish. With Firefox whatever changes you want are limited only by your willingness to implement them (either by doing the work yourself or working with others to get those changes made).

You can even distribute the improved Firefox variant browser to others and help the community. Hacker News recently had a story about some hackers doing exactly this with a variant they call Librefox. Other examples of Firefox variants include IceCat and the Tor Browser.

Re:CSS grid garden by PavlovsCat on Monday December 24, 2018 @01:56PM (#18753636)
Is there a browser you would recommend, if we ignored their HTML/CSS rendering for a second, based on ethical considerations, so to speak? I like making things compatible when I don't need anything modern, and would be interested in hearing about any browsers you think are worth supporting.
Re:CSS grid garden by smbullet on Tuesday December 25, 2018 @12:43AM (#18756132)
I would be very interested in this as well. Especially as someone who makes silly browser extensions they never intend to publish.
Re:CSS grid garden by twblalock on Monday December 24, 2018 @03:24PM (#18754095)
Your definition of walled garden is pretty broad and includes all major browsers.
Re:CSS grid garden by smbullet on Tuesday December 25, 2018 @12:42AM (#18756129)
Well yeah, they basically said that in their original comment. Is it not possible for all major browsers to be walled gardens?
Re:CSS grid garden by saagarjha on Monday December 24, 2018 @02:01PM (#18753670)
Is there a way to enable unsigned extensions at all, say from about:config?
Re:CSS grid garden by ChrisSD on Monday December 24, 2018 @02:35PM (#18753841)
You can either use the developer build or compile Firefox yourself.
Re:CSS grid garden by Vinnl on Monday December 24, 2018 @03:04PM (#18753986)
Extended Support Releases do still include the flag: https://support.mozilla.org/en-US/kb/add-on-signing-in-firef...
Re:CSS grid garden by superkuh on Monday December 24, 2018 @02:15PM (#18753738)
No. The removed that in the low 40s versions.