You can read my article about generators
However, generators, being subset of CSP, are very powerful, and we can build really interesting workflows with them. I have to note, though, that I don't consider this as a production library, since they are really "obscure", and you should treat them more like a gist and inspiration, rather than reference implementation. They are hard to understand to the newcomer to your codebase, so you should think twice before implementing.
- Batch/scheduling example | source code
- Pause/resume example | source code
- Ignore errors example | source code
- Cancel example | source code
You can run these example using following commands:
npm run example:batch npm run example:pause npm run example:ignoreErrors
Because they are not very common to typical codebases – it makes them weird automatically :) No worries, though – in case it fits your use-case perfectly, take it and adapt to your scenario.