BoolType
February 3, 2026 ยท View on GitHub
BoolType()
Validates whether the type of the input is boolean.
v::boolType()->assert(true);
// Validation passes successfully
v::boolType()->assert(false);
// Validation passes successfully
Templates
BoolType::TEMPLATE_STANDARD
| Mode | Template |
|---|---|
default | {{subject}} must be a boolean |
inverted | {{subject}} must not be a boolean |
Template placeholders
| Placeholder | Description |
|---|---|
subject | The validated input or the custom validator name (if specified). |
Categorization
- Booleans
- Types
Changelog
| Version | Description |
|---|---|
| 1.0.0 | Renamed from Bool to BoolType |
| 0.3.9 | Created as Bool |