Humza's Blog

Humza's Blog

💪Polyfills in JavaScript

Setting the background 🖼

Well, I am bored! After working on 4 Reactjs projects and stopping another one-two (or maybe three) midway. I feel a bit lost and thus I decided to write this article just to look back on the things I have been through, not in life 😢 but in Javascript. 🙄

First things first, let's address the elephant in this blog 🐘

What is Polyfill in JavaScript?

Polyfill is a piece of code that implements a feature or function which we expect the browser to run or support natively out of the box.

But unlike us, browsers aren't that smart. 😎

Or you can think of polyfill as the superpower you give to older browsers to understand modern functionalities.

So without further ado let's get started. ↙

▶ We will move first to Strings followed by Array and then Object. (not decided anything yet) 😅

Hop onto this 👉 link to discover some polyfills of few String methods.

Share this