fly-rollup

2.1.0 • Public • Published

fly-rollup

fly badge npm badge download badge travisbadge license badge

Rollup plugin for Fly .

Install

This plugin requires Fly .

npm i --save-dev fly-rollup

Usage

Async/Await flavored:

export async function roll (fly) {
  await fly
    .source('src/entry.js') // just pass your entry file(s) here
    .rollup({
      rollup: { // rollup options
        plugins: [
          require('rollup-plugin-babel')()
        ]
      },
      bundle: { // bundle options
        format: 'es'
      }
    })
    .target('dist')
}

Generator function flavored:

exports.roll = function * (fly) {
  yield fly
    .source('src/entry.js') // just pass your entry file(s) here
    .rollup({
      rollup: { // rollup options
        plugins: [
          require('rollup-plugin-babel')()
        ]
      },
      bundle: { // bundle options
        format: 'es'
      }
    })
    .target('dist')
}

You just need to pass entry files to fly-rollup .

Sourcemap

Sourcemap is controlled by sourceMap key in bundle options. It has 3 options:

  • true: default value, generate external sourcemap along with bundle output.
  • 'inline': inline sourcemap.
  • false: disable sourcemap.

e.g.

fly.source
  .rollup({
    bundle: {
      sourceMap: false // disable sourcemap
    }
  })

For other options:

See Rollup JavaScript API#rollup.rollup( options ) for rollup options .

See Rollup JavaScript API#bundle.generate( options ) for bundle options .

License

Do What The F*ck You Want To Public License

Readme

Keywords

Package Sidebar

Install

npm i fly-rollup

Weekly Downloads

1

Version

2.1.0

License

WTFPL

Last publish

Collaborators

  • frantic1048