In this Hasty Treat, Scott and Wes continue a three-part series about old browsers, fallbacks and polyfills. In part two, they talk specifically about CSS Grid, Flexbox, new features and fallbacks, and how to use them.
VueSchool.io — Sponsor
Check out VueSchool.io's new subscription plans. Get access to their entire catalog with more than 160 lessons, including The Vue.js Masterclass, for one low monthly fee. New content and courses are added regularly. Visit VueSchool.io/syntax and get your first month for only $5.
3:08 - CSS Grid and Flexbox
- Flexbox old spec
- Flexbox new spec
- CSS Grid
- Some popular options for supporting for supporting CSS Grid and/or Flexbox:
- Just serve the mobile layout
- Display block
- Separate layout that you will eventually delete
- Can I Use
- Do websites need to look exactly the same in every browser?
- CSS3, Please!
12:38 - CSS Variables
- Double define
- Just like Grid, unknown def will be ignored and fallback to CSS
- CSS Houdini
17:00 - Fallback Code
- Display block then display grid
- Feature Testing
- Detect the browser as a last resort