https://github.com/cushjs/cush-plugin-nebu
Javascript plugins for cush
https://github.com/cushjs/cush-plugin-nebu
cush cush-plugin nebu
Last synced: 10 months ago
JSON representation
Javascript plugins for cush
- Host: GitHub
- URL: https://github.com/cushjs/cush-plugin-nebu
- Owner: cushJS
- Created: 2018-07-18T23:38:27.000Z (almost 8 years ago)
- Default Branch: master
- Last Pushed: 2018-07-21T23:40:25.000Z (almost 8 years ago)
- Last Synced: 2025-07-20T16:02:39.821Z (11 months ago)
- Topics: cush, cush-plugin, nebu
- Language: CoffeeScript
- Homepage: https://github.com/aleclarson/nebu
- Size: 2.93 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# cush-plugin-nebu v0.1.0
An alternative to [Babel][1] for plugins that transform Javascript.
### [Learn more][2]
[1]: https://github.com/babel/babel
[2]: https://github.com/aleclarson/nebu
## 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.
```js
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.
```js
// cush.config.js
this.worker(function() {
this.hook('nebu', (asset, state) => {
// The state is unique to each asset and updated by nebu plugins.
});
});
```