Some cool ideas of things to do with CSS variables; now supported by all modern browsers
CSS variables now enjoy wide cross-browser support. But what are they and why should we use them?
Any CSS property — color, size, position, etc. — can be stored in a CSS variable. Their names are all prefixed with –, and you declare them by adding them to an element right where you add its other styles.
Read more from the source: vgpena.github.io
Chris Coyier writes:
Cool, right? But still, how actually useful is that? What are the major use cases? I think we’re still seeing those shake out.
Read more from the source: CSS-Tricks
Last week, I wrote about how I created the bitsofcode logo animation with CSS. After that, it was suggested that I attempt a comparison between a CSS animation and the Web Animations API, so here it is! Introduction to the Web Animations API As with last week, I’ll start this
Read more from the source: bitsofcode
CSS Grids may reduce your need for media queries
CSS Grid is the most critical layout feature to come to browsers since Flexbox. It allows us to escape some of the magic numbers, hacks, and workarounds that we’ve grown accustomed to using for the last 15 years. It brings simplicity to declaring layouts that will tear a chunk out of most of the major CSS frameworks, and reduce bloat in our own hand crafted styles.
If you’re not familiar with what CSS Grid is, and you’ve made it this far, it’s a layout tool that applies to a containing element which then manages how the child elements are spaced, sized, and aligned.
CSS Grid gives us powerful new abilities — most notably for layout to be aware of both horizontal and vertical space at the same time, for changes to layout not to impact markup, and the ability adapt to available space without the need for media queries.
Read more from the source: Campaign Monitor Engineering
Firefox is taking a one-piece-at-a-time strategy to replace the Gecko rendering engine with a modern one coded in Rust.
Mozilla’s been working on a brand new, top-secret engine. Except it’s totally not top-secret. Never was. At another company it would have been a top-secret project. At Mozilla, it’s all done out in the open.
The project is called Servo. It was started as an experiment. It’s coded in a new programming language called Rust. (Gecko is written in C++.) And it’s open source. You can totally help us make it.
Read more from the source: jensimmons.com
Every country flag using only a single element, CSS, and fonts.
Flags of the world in just one div
View all at CSS Flags