I've noticed it in my company's codebase and it has 30M downloads per week so I'm curious about its importance.
regenerator-runtime
is the runtime support for compiled/transpiled async
functions. (It may well have other uses, but this is the predominant one.)
When you use a compiler like Babel that compiles modern JavaScript into earlier JavaScript (a process sometimes called transpiling), one of the things you can do is compile async
functions to something that will run on JavaScript engines that don't support async
functions (such as the increasingly-irrelevant IE11). Babel does the syntax transformation, but the resulting code relies on runtime support from regenerator-runtime
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With