Closed nodren closed 6 years ago
Why would you like to target es5
when Nest is compiled to es6
?
when using typescript client side via ts-loader & webpack, need to target es5 for browser compatibility.
my work around was to have two different tsconfig files, one webpack listens to, and another nest listens to
my work around was to have two different tsconfig files, one webpack listens to, and another nest listens to
This is the only possible solution actually.
@kamilmysliwiec Would you please please please make note of this in the README.md. I just spent hours debugging Nest to find that the issue was caused by the target in the tsconfig. It is pretty common for angular/nest repos to have a target of es5 in the root of the project.
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.
If you take the nestjs/typescript-starter repo, and changing the
target
to es5 in tsconfig(and addinglib: ['es6']
)ApiModelProperty defined properties no longer are described in swagger. running this correctly gives me a /api route with swagger ui, but the TestBody definition doesn't exist
app.controller.ts File:
tsconfig.json file: