covenix / Principal
Variable: Principal
constPrincipal: (data?) =>ParameterDecorator
Defined in: src/parameters.ts:175
Injects the principal returned by the route's @Security handler (e.g. the authenticated user). Only meaningful on a route guarded by @Security; on an unguarded route it resolves to undefined. Built on createParamDecorator — it's the canonical example of a custom injected value.
Parameters
data?
undefined
Returns
ParameterDecorator
