@hugov/cjs-to-iife

0.1.4 • Public • Published

cjs-to-iife

small simple bundler

Examples

const code = require('cjs-to-iife')('./commonjsmodule.js')

Notes

  • returns the promise of a string
  • sets this.exports.name or this.exports.default. Uses the following rollup options
    • format: 'iife'
    • extend: true
    • exports: 'named'
    • name: 'exports'

License

MIT © Hugo Villeneuve

Package Sidebar

Install

npm i @hugov/cjs-to-iife

Weekly Downloads

1

Version

0.1.4

License

MIT

Unpacked Size

2.4 kB

Total Files

6

Last publish

Collaborators

  • hugov