#Custom Param Decorator with baked in config from config module

5 messages · Page 1 of 1 (latest)

upbeat condor
#

I want to make a custom param decorator that pulls a header from the request. This is mostly so I can have type safety without having to do the isArray check everywhere I use this header. The key for the header is provided by my config service, from my config module. How can I construct and use a custom param decorator that's as convenient as createParamDecorator while baking in a string from my config module?

quasi tiger
upbeat condor
quasi tiger
#

Oops sorry. Wrong thread. 😊

upbeat condor
#

Bump. If I'm asking something fundamentally impossible that would be good to know too