Norvica [Validation]

A simple and extensible PHP validation library

Get Started →

Validate Scalar Values

Validate single values such as strings, numbers, booleans.

    value: '[email protected]',
    rules: new Email(),

Learn more about scalar values validation →

Validate Arrays

Validate arrays of data, applying rules to individual elements.

    value: ['email' => '[email protected]'],
    rules: ['email' => new Email()],

Learn more about array validation →

Validate Objects

Validate data objects, ensuring that their properties conform to specific rules.

readonly class SomeDto {
    public function __construct(
        public string $email,
    ) {}

    value: new SomeDto(email: '[email protected]'),

Learn more about object validation →

Validate Collections

Validate collections of values.

    value: ['', ''],
    rules: new EachX(new Ip()),

Learn more about collection validation →