gobble-esperanto-bundle
Bundle ES6 modules with gobble and esperanto
Last updated 4 years ago by rich_harris .
MIT · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install gobble-esperanto-bundle 
SYNC missed versions from official npm registry.

gobble-esperanto-bundle

Bundle ES6 modules with gobble and esperanto.

Installation

First, you need to have gobble installed - see the gobble readme for details. Then,

npm i -D gobble-esperanto-bundle

Usage

gobblefile.js

var gobble = require( 'gobble' );
module.exports = gobble( 'src' ).transform( 'esperanto-bundle', {
  entry: 'app.js' // you must specify an entry module. The '.js' is optional
});

This will create a single AMD module file that contains app.js and all its dependencies (and their dependencies, and so on) that Esperanto finds in src. By default it will also be called app.js - you can change it to something else with the dest option.

Additional options

You can specify a type of module:

  • type: 'amd' (the default) - Asynchronous Module Definition, used by RequireJS and its ilk
  • type: 'cjs' - CommonJS, for use in node or with Browserify
  • type: 'umd' - Universal Module Definition. Works as AMD, CommonJS, or browser global. You must supply a name option for the global export.

Sourcemaps are generated by default. If you don't want to create a sourcemap, pass sourceMap: false, or pass sourceMap: 'inline' to append the sourcemap to the bundle as a data URI.

For strict mode output, pass strict: true.

License

MIT. Copyright 2014 Rich Harris

Current Tags

  • 0.2.1                                ...           latest (4 years ago)

10 Versions

  • 0.2.1                                ...           4 years ago
  • 0.2.0                                ...           4 years ago
  • 0.1.7                                ...           5 years ago
  • 0.1.6                                ...           5 years ago
  • 0.1.5                                ...           5 years ago
  • 0.1.4                                ...           5 years ago
  • 0.1.3                                ...           5 years ago
  • 0.1.2                                ...           5 years ago
  • 0.1.1                                ...           5 years ago
  • 0.1.0                                ...           5 years ago
Maintainers (1)
Downloads
Today 0
This Week 0
This Month 10
Last Day 0
Last Week 10
Last Month 7
Dependencies (2)
Dev Dependencies (0)
None

Copyright 2014 - 2016 © taobao.org |