nanocomponent
nanocomponent copied to clipboard
component.use
As per our talk 2 weeks ago, it'd be useful to start thinking of component.use().
The goal of this API would be to provide a way to extend components the way we extend choo with app.use().
Not quite sure on the API yet, but got a hunch that using an internal event emitter would be the way to go for this. Input very welcome!
Maybe provide a function that gets a copy of this/self and emit that emits lifecycle events?
yes! component middleware!