|
|
## game.dto.ts
|
|
## DTO
|
|
|
|
|
|
|
|
### NewGameDTO
|
|
|
|
|
|
|
|
|
|
`ValidateNested()` and `Type(() => DTO)` is needed for ValidationPipe to validate nested DTOs.
|
|
`ValidateNested()` and `Type(() => DTO)` is needed for ValidationPipe to validate nested DTOs.
|
|
|
|
|
|
|
|
? in the key's name means, that the key-value pair is optional.
|
|
? in the key's name means, that the key-value pair is optional.
|
|
|
|
|
|
|
|
|
### NewGameDTO
|
|
|
|
|
|
|
```typescript
|
|
```typescript
|
|
|
export class newGameDTO {
|
|
export class newGameDTO {
|
|
|
@IsString()
|
|
@IsString()
|
| ... | |
... | |
| ... | | ... | |