I am trying to download files using loopback4, showing error message, Equivalent of res.download() (ExpressJS) in the controlller for downloading files #2037.Router: allow methods to return an async-iterator or a readable stream #122.LB3 implementation: strongloop/strong-remoting#284.Documentation: explain how a route can specify the response headers and provide body as a readable stream.Nice to have: a helper function similar to res.download provided by Express that will accept a file name and create an LB4 response object with all necessary fields correctly filled (content type, content disposition, body stream, etc.).It should be possible for routes to provide the response body as a ReadableStream and Buffer too.This is already covered by the issue #436. Content-Disposition: attachment filename="filename.jpg"). A route (a controller method) must be able to specify not only the response body, but also additional response headers (e.g.To allow LB4 applications to implement file downloads, we need to make improvements in several areas:
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |