@nestjs/core
Version:
The core of NestJS, a TypeScript framework for Node.js backends: modules, dependency injection and the request pipeline, on Express, Fastify or node:http.
16 lines (15 loc) • 437 B
JavaScript
import { RouteParamtypes } from '@nestjs/common/internal';
export class ParamsTokenFactory {
exchangeEnumForString(type) {
switch (type) {
case RouteParamtypes.BODY:
return 'body';
case RouteParamtypes.PARAM:
return 'param';
case RouteParamtypes.QUERY:
return 'query';
default:
return 'custom';
}
}
}