Speeding up the JavaScript ecosystem - Polyfills gone rogue

https://marvinh.dev/blog/speeding-up-javascript-ecosystem-part-6/

21 points · 1 comments · view on lemmy.world

1 Comments

not_woody_shaw@lemmy.world · 6 pts · 2y

When there is no need for the polyfill it should do nothing. The odd thing to me is that the functions were used directly like a function from a library.

This comes from the days of competing slightly-different polyfills. If you depend on the behaviour of one specific polyfill you don't want to worry about some other package overwriting your polyfill with a different slightly incompatible one, thereby breaking your feature.

Slightly shocking that nobody is doing the maintenance to remove these old redundant polyfills tho.