You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Currently in express/koa we have multer, hapi itself can handle file upload.
I've notice that we provides multerOptions in tsoa.json for preset a global multer instance.
But such option is not event fit for hapi users.
When the #1483 gives the idea of custom instance of multer,
I think its time to make something more 'general' for all users.
Here is my proposal:
Stop using tsoa.json's multerOptions, we can mark it as deprecated, after keep supporting it for few versions then remove it.
Define a global(for express/koa multer & hapi config) file upload config as RegisterRoutes parameter, allow users to provide it in there server.ts.
There must be some needs on setting different upload destination path or file size limitation for endpoints, thus, we should introduce some kind of decorator like @UploadOptions takes more options and merge with default global configuration to provides different uploading setup for each endpoint.
The text was updated successfully, but these errors were encountered:
Currently in express/koa we have multer, hapi itself can handle file upload.
I've notice that we provides multerOptions in tsoa.json for preset a global multer instance.
But such option is not event fit for hapi users.
When the #1483 gives the idea of custom instance of multer,
I think its time to make something more 'general' for all users.
Here is my proposal:
RegisterRoutes
parameter, allow users to provide it in there server.ts.@UploadOptions
takes more options and merge with default global configuration to provides different uploading setup for each endpoint.The text was updated successfully, but these errors were encountered: