Downloadable code used to add new functionality to browsers.
Questions tagged [polyfills]
890 questions
450
votes
6 answers
What is the difference between a shim and a polyfill?
Both seem to be used in web development circles, see e.g. HTML5 Cross Browser Polyfills, which says:
So here we're collecting all the shims, fallbacks, and polyfills...
Or, there's the es5-shim project.
In my current project we're using a number…

Domenic
- 110,262
- 41
- 219
- 271
414
votes
6 answers
What is the meaning of polyfills in HTML5?
What is the meaning of polyfills in HTML5? I saw this word in many sites about HTML5, e.g. HTML5-Cross-Browser-Polyfills.
So here we're collecting all the shims, fallbacks, and polyfills
in order to implant HTML5 functionality in browsers that…

Jitendra Vyas
- 148,487
- 229
- 573
- 852
146
votes
7 answers
How do I install the babel-polyfill library?
I just started to use Babel to compile my ES6 javascript code into ES5. When I start to use Promises it looks like it's not working. The Babel website states support for promises via polyfills.
Without any luck, I tried to…

Shlomi
- 3,622
- 5
- 23
- 34
114
votes
5 answers
IE11 - does a polyfill / script exist for CSS variables?
I'm developing a webpage in a mixed web browser environment (Chrome/IE11).
IE11 doesn't support CSS variables, is there a polyfill or script that exists that would allow me to use CSS variables in IE11?

R. StackUser
- 2,005
- 4
- 17
- 24
86
votes
13 answers
How do I support Internet Explorer in an Angular 8 application?
When I generate a project with Angular CLI (8.0.0), I run ng serve, open the application up in Internet Explorer and I am presented with a blank screen.
I had a look at the polyfills.ts files and I uncommented the following lines:
import…

James Barrett
- 2,757
- 4
- 25
- 35
85
votes
2 answers
How to support promises in Internet Explorer 11?
I have a simple code that runs perfectly on every browser except for the Internet Explorer 11. How can I make it work on all browsers?
Codepen
'use strict';
let promise = new Promise((resolve, reject) => {
setTimeout(() => {
…

Billy Logan
- 2,470
- 6
- 27
- 45
73
votes
3 answers
Angular4 Application running issues in IE11
I am building a Angular4 project using Angular CLI (1.1.2). It runs perfectly in Chrome (Version 59.0.3071.115) and firefox(54.0.1) but when I tried to use IE11 (Verison 11.0.9600.18738) nothings shows up and when I open the develper mode in IE, it…

Terry Zhang
- 4,541
- 8
- 23
- 29
58
votes
8 answers
Why IE 11 display blank page rendering react app
I have an issue with IE 11 and my react app. I use Webpack, babel and polyfill.io cdn and all is nice until rendering bundeled file, then it stops doing anything.
Do you have any idea what may go wrong?

itgirl1234
- 751
- 2
- 6
- 15
55
votes
1 answer
Shim vs. Sham: What is the difference?
What is the difference between a shim an a sham?
Is it enough to include es5-shim.min.js and es6-shim.min.js or should I also include es5-sham.min.js and es6-sham.min.js?

garbanzio
- 846
- 1
- 7
- 10
48
votes
7 answers
Getting Error Promise is undefined in IE11
I am converting React code to typescript,
target in tsconfig is es5.
on running in IE 11 i get an error "Promise is undefined"
I know i need to polyfill,but how?
I am not using Babel.
Following is my Webpack.config
var webpack =…

Ankit Raonka
- 6,429
- 10
- 35
- 54
45
votes
3 answers
Modernizr with Respond.js
I am carefully assessing the best way to utilize Modernizr and Respond.js for responsive design and have a couple of questions for the community.
Firstly, it is my understanding that when bundling Modernizr with Respond.js, no other coding or tests…

dropseed
- 451
- 1
- 4
- 4
45
votes
9 answers
How can I polyfill Promise with webpack?
I'm using webpack to bundle up my JavaScript. I'm depending on modules like popsicle which use any-promise.
Here's my code:
var popsicle = require('popsicle');
popsicle.get('/').then(function() {
console.log('loaded URL');
});
This works fine in…

Wilfred Hughes
- 29,846
- 15
- 139
- 192
42
votes
3 answers
html5 forms with polyfills - is it worth it?
Despite all of the buzz around html5 forms, it seems to me like you are creating extra work, in most scenarios, by going this route.
Take, for example, a datepicker field. The native html5 implementation of this renders differently in every…

drogon
- 1,785
- 3
- 21
- 34
40
votes
6 answers
Using ApolloClient with node.js. "fetch is not found globally and no fetcher passed"
I am attempting to use an Apollo Client on a node.js server to interface with another GraphQL API using the following code:
import fetch from 'node-fetch'
import { createHttpLink } from 'apollo-link-http'
import ApolloClient from…

Nathan
- 1,897
- 2
- 15
- 16
32
votes
6 answers
Angular2 Final Release - "Error: Angular requires Zone.js prolyfill"
I have upgraded from RC4 to the Final release of Angular2. When I run npm start, the app is stuck on 'Loading...' the only error I get is about Zone.js:
Basically, typeof Zone is undefined:
Here is my package.json:
"engines": {
"node": ">=…

jhhoff02
- 1,179
- 1
- 17
- 24