Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.
Start your free trialBrenda Krafft
18,036 PointsIf my application isn't going to be live for at least a year, is it OK to code it all in Flexbox? Or is that risky?
My sense is that by the time I've got my act together and this entire thing built, Flexbox should be pretty well supported.
What advice would you give?
2 Answers
Christopher Aporta
24,258 PointsHey Brenda & Craig,
There's actually a really awesome tool out there on the interwebs that provides a solution to your concerns specifically. It's called Modernizr. It was built by a team of front-end gurus, and it's essentially a JavaScript library that detects HTML5 and CSS3 features in a user's browser.
In short, it will detect a browser's features at load time, and then add classes accordingly to the HTML for you to hook CSS styles onto. If a given class isn't present because of browser limitations, the CSS inside it won't load.
This helps you utilize newer technologies like Flexbox, but only in the situations that call for them. It's a great way to build modular, progressive webpages without sacrificing 'backwards compatibility'. Check it out!
Best,
Chris
P.S. Craig - Lea Verou's -prefix-free is another great tool that cuts out the need for constant vendor prefixing - It works in the background, adding current browser prefixes only when needed.
Craig Watson
27,930 PointsHi Brenda,
I was thinking the same thing for my personal site, with the number of updates and changes along with browser compatibility changing with flex box, if you were to code now you may miss out on lots of cool features that may come along in the future.....
Also you may be prefixing now and in a years time have a whole load of code that is not nessasery to your site and although small will be having an impact on your sites loading time.
I went for bootstap frame work with its fluid grid :) very cool
Hope this helps!
Craig
Brenda Krafft
18,036 PointsAh... good points. I suppose that the other issue is that I'm going to need to understand the other layout methods as well.