Skip to content

Commit df9edf9

Browse files
authored
Update README.md
1 parent 5a28f93 commit df9edf9

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

README.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -573,9 +573,11 @@ validate(user, {
573573
There is also a special flag `always: true` in validation options that you can use. This flag says that this validation
574574
must be applied always no matter which group is used.
575575

576-
## Validation validateIf
576+
## Validation option validateIf
577577

578-
If you want to validate that condition by object, you can use validation validateIf.
578+
If you want an individual validaton decorator to apply conditionally, you can you can use the option `validateIf` available to all validators.
579+
This allows more granular control than the `@ValidateIf` decorator which toggles all validators on the property, but keep in mind that
580+
with great power comes great responsibility: Take care not to create unnecessarily complex validation logic.
579581

580582
```typescript
581583
class MyClass {

0 commit comments

Comments
 (0)