Layout on the web is certainly an extremely time consuming process and the most outdated. Floats and such still don’t cut it. At it’s core, Grid Style Sheets (GSS) reimagines CSS layout and harnesses the Cassowary Constraint Solver – the same algorithm Apple uses to compute native layout. OK sounds good, but is it a pre-processor? Well… no not exactly.
GSS enables far better layout control through building relational rules between different elements. Let’s take CSS and bend it to our will as we look into the layout capabilities of the GSS project.
Test Drive GSS on GitHub
The Purpose of GSS
Ever tried to center something in CSS? The plethora of techniques and methods are astounding! Current centering methods in CSS use approaches such as flexbox, table display, inline-block, transforms, absolute positioning…the list goes on and on when all we want to do is center something!
I’m also sure you’ve all heard of element queries, but why are they so difficult to obtain right now? The answer is cyclic dependencies that naturally arise in relative layout logic and arithmetic. That means if we have 3 boxes and each box depends on the width of the previous one we end up in a never ending loop. For example…Read the full article on Web Design Weekly