New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
support streams #23
Comments
Oh, nice. I just landed on this issue by accident. I also need something like that in my setup. Or would you allow a custom content type by passing it somewhere? e.g. fastify.get('/documents', function (opts, reply) {
// returns a stream in object mode
var stream = database.select('*').from('documents').toStream()
// Set content type on stream
stream['Content-Type'] = 'application/x-ndjson'
reply(null, stream)
// or
reply(null, stream, {'Content-Type': 'application/x-ndjson'})
}) |
I think we should do something with |
I'm working on stream support at the moment, in the next days will land a pr :) |
Stream support added in #27. |
We should be able to call
reply(null, stream)
.The text was updated successfully, but these errors were encountered: