Externalise references to helpers and builtins, automatically polyfilling your code without polluting globals
Externalise references to helpers and builtins, automatically polyfilling your code without polluting globals
``sh`
$ npm install babel-plugin-transform-runtime
.babelrc
`json`
{
"plugins": ["transform-runtime"]
}
`sh`
$ babel --plugins transform-runtime script.js
`javascript``
require("babel-core").transform("code", {
plugins: ["transform-runtime"]
});