Skip to content

Tags

@tsed/schema

Usage ​

typescript
import { Tags } from "@tsed/schema";

See /packages/specs/schema/src/decorators/operations/tags.ts.

Overview ​

ts
function Tags(...tags: (string | OpenSpecTag)[]): ClassDecorator & MethodDecorator;

Description ​

Add metadata tags to the decorated element (class or method).

Examples ​

On method ​

typescript
@Controller("/")
class MyController {
 @Tags("api")
 get() {}
}

On Class ​

typescript
@Controller("/")
@Tags("api")
class MyController {
 get() {}
}

Released under the MIT License.