/cush-plugin-nebu

Javascript plugins for cush

Primary LanguageCoffeeScript

cush-plugin-nebu v0.1.0

An alternative to Babel for plugins that transform Javascript.

Configuration

Each package can have its own nebu.config.js module that customizes its plugins and other options.

Your cush.config.js module can configure the nebu.plugins property too, but it needs to be in a worker first.

this.worker(function() {
  this.merge('nebu.plugins', [
    // nebu plugins go here
  ]);
});

The "nebu" hook provides access to the state of each asset after its plugins are used.

// cush.config.js
this.worker(function() {
  this.hook('nebu', (asset, state) => {
    // The state is unique to each asset and updated by nebu plugins.
  });
});