JSPM

rollup-plugin-es3

1.1.0
  • ESM via JSPM
  • ES Module Entrypoint
  • Export Map
  • Keywords
  • License
  • Repository URL
  • TypeScript Types
  • README
  • Created
  • Published
  • Downloads 32109
  • Score
    100M100P100Q150853F
  • License MIT

Make rollup compatible with ES3, remove Object.defineProperty of __esModule part

Package Exports

  • rollup-plugin-es3

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (rollup-plugin-es3) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

rollup-plugin-es3

Build Status

Rollup plugin, to make it more compatible with ES3.

Currently it's only do 2 things:

  • Remove Object.defineProperty of __esModule part (rollup issue #750)
  • Remove Object.freeze (issue #1)

Install

npm i rollup-plugin-es3 -D

Usage

import { rollup } from 'rollup'
import es3 from 'rollup-plugin-es3'

rollup({
    entry: 'main.js',
    plugins: [
        es3()
    ]
})

Option

// pass the list of removal
    plugins: [
        es3({ remove: ['defineProperty', 'freeze'] })
    ]