budo icon indicating copy to clipboard operation
budo copied to clipboard

Using budo as middleware

Open kolya-ay opened this issue 8 years ago • 3 comments

I'm looking for a way to attach budō to existing express app (in dev mode). It would be cool if it could be used programmatically as middleware instead of writing custom code that way. Quick look at the source convinced me that it is not something impossible as budō acts allready as middleware composer (correct me if I'm wrong).

The api could be budo.middleware(options) or budo(options).middleware() with budo(options).listen(port) to match express style. This is probably related to #122 and #91

kolya-ay avatar Jun 13 '16 18:06 kolya-ay

That seems like outside the scope of budo. There's browserify-middleware for that, IIRC.

mightyiam avatar Aug 10 '16 01:08 mightyiam

I think it might be worth pulling the budo core into its own module. In other projects I've needed something like that. 😊 Just a matter of finding time.

mattdesl avatar Aug 10 '16 03:08 mattdesl

Just bumping this issue to say I'd also love to see this feature. Though I'm accustomed to Express I've been looking at using Koa as well.

spacejack avatar Aug 14 '18 00:08 spacejack