respect-validation/docs/Type.md
Henrique Moody 2a2e1d577e
Change how documentation of rules are presented
Rules are not always used from the alias `v`, neither called staticaly.
2017-03-27 17:26:21 +02:00

695 B

Type

  • Type(string $type)

Validates the type of input.

v::type('bool')->validate(true); // true
v::type('callable')->validate(function (){}); // true
v::type('object')->validate(new stdClass()); // true

See also: