Nestjs-custom-decorators
A set of nestjs custom decorators.
User decorator
A param decorator that fetches the request.user
(could be added by a middleware or a guard) and add it to the params.
Usage:
public getUser@User user: any: void
DecodeJWT
A param decorator that decodes the JSON web token added to the request by a middleware or a guard and add it to the params.
Usage:
public getDecodedJWT@DecodeJWT decodedJwt: any: void