babel-polyfill-loader

1.0.1 • Public • Published

npm

babel-polyfill-loader

A webpack loader that generates a customized babel polyfill

Installation

npm install babel-polyfill-loader

Usage

Add a babel-polyfill.json file to your project:

{
  "modules": [
    "es6.object.assign",
    "es6.array.find",
    "es6.array.find-index",
    "es6.array.from",
    "es6.string.starts-with",
    "es7.array.includes",
    "es6.symbol"
  ],
  "library": false
}

See the core-js README for more options.

Add an entry to your webpack config:

entry: {
  polyfill: 'babel-polyfill-loader!'
}

Or require the loader in your project:

require('babel-polyfill-loader!')

License

MIT

Readme

Keywords

none

Package Sidebar

Install

npm i babel-polyfill-loader

Weekly Downloads

13

Version

1.0.1

License

MIT

Last publish

Collaborators

  • jstern