# Hidden Decorator swagger
Module | import { Hidden } from "@tsed/swagger" |
---|---|
Source | /packages/swagger/src/decorators/hidden.ts |
# Overview
function Hidden(): Function;
# Description
Hide a route or all route under in the decorated controller from the documentation.
@Controller('/')
export class Ctrl {
@Get('/')
@Hidden()
hiddenRoute(){
}
}
@Controller('/')
@Hidden()
export class Ctrl {
@Get('/')
hiddenRoute() {
}
@Get('/2')
hiddenRoute2() {
}
}
@Controller('/')
export class Ctrl {
@Get('/')
hiddenRoute(@Hidden() @QueryParams() param: string){
}
}
```
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
- Session & cookies
- Passport.js
- TypeORM
- Mongoose
- GraphQL
- Socket.io
- Swagger
- AJV
- Multer
- Serve static files
- Templating
- Throw HTTP Exceptions
- Customize 404
- AWS
- Jest
- Seq
- Controllers
- Providers
- Model
- Converters
- Middlewares
- Pipes
- Interceptors
- Authentication
- Hooks
- Injection scopes
- Custom providers
- Custom endpoint decorator
- Testing