With all these fantastic new features
in HTML5, it can be disappointing to find not all of them play nice with the legacy browsers we are required to support. Thankfully, this is where polyfills come in. The term polyfill was first coined by Remy Sharp in 2009 when he was writing “Introducing HTML.” Remy stated “Shim, to me, meant a piece of code that you could add that would fix some functionality, but it would most often have its own API. I wanted something you could drop in and it would silently work.”http://remysharp.com/2010/10/08/what-is-a-polyfill/.
So as per Remy’s definition, a polyfill is a bit of code that simply adds the missing functionality to the browser, which is normally achieved using JavaScript. The term is not meant to implicate older browsers as often newer browsers also need to be polyfilled with the latest features.
There are already a significant number of polyfills available for HTML5 technologies, some of the popular ones are:
1. Respond.js: https://github.com/scottjehl/Respond Respond.js
adds support for min/max-width CSS3 Media Queries to older versions of Internet Explorer (IE6-8).
If you are planning on making mobile first responsive sites and need to support older IE,
this is required.
2. HTML5 Shiv: https://github.com/aFarkas/html5shiv HTML5 Shiv enables support for
styling HTML5 semantic elements in older versions of Internet Explorer.
3. CupCake.js: http://www.rivindu.com/p/cupcakejs.html CupCake.js adds support to
both localStorage and sessionStorage with a generic API.
4. FlashCanvas: http://flashcanvas.net/ HTML5 Canvas Polyfill based on using Adobe Flash.
Comments
Post a Comment