I am getting an image file and other parameters in a single form. I am using routing-controller (npm library) decorator to get the file @UploadedFile("image") file?: any and getting other params in body @Body({ required: true }) review: ReviewInput. Is there any good way to get these params?
ReviewInput is my defined type which contains the string params following is the code where I am getting params:
@Post("/review")
async addReview(
@Body({ required: true }) review: ReviewInput,
@UploadedFile("image") file?: any,) {
return AddReviewsUsecase.execute(review, file);
}