Skip to content
This repository was archived by the owner on Jan 9, 2023. It is now read-only.

Commit

Permalink
docs(readme): add example
Browse files Browse the repository at this point in the history
  • Loading branch information
wmzy committed Aug 20, 2019
1 parent c426640 commit becf789
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ This plugin (maybe not a plugin) gives you a slightly elegant and efficient solu
import plugins, {when, whenAll, prop, format, file} from 'rollup-plugin-by-output';
```
### plugins
### Plugins
```js
{
Expand All @@ -84,7 +84,7 @@ The filter is a predicate function, the parameter is an output config object. If
`when` and `whenAll` is convenient for few filters and `plugins` is convenient for multiple filters.
### filter helpers
### Filter helpers
There are three [simple](https://github.com/wmzy/rollup-plugin-by-output/blob/master/src/index.js#L53) but useful filter helpers: `prop`, `format`, `file`.
Expand All @@ -111,6 +111,10 @@ format = filter => prop('format', filter)
file = filter => prop('file', filter)
```
## Examples
* [lib-starter](https://github.com/wmzy/lib-starter/blob/master/rollup.config.js)
## Workflow
```bash
Expand Down

0 comments on commit becf789

Please sign in to comment.