Valida...nLength(3pm)

πŸ“¦
version 7.900059 Β· 7 versions
, in debian trixie, ubuntu noble, ubuntu resolute, ubuntu stonking

✨ NAME ✨

okay so bestie, welcome to Validation::Class::Directive::MinLength πŸ’– β€” it's the MinLength Directive for Validation Class Field Definitions, and yes that's a whole mouthful but it's literally just the little rule that checks how long your stuff is πŸŽ€


🌸 VERSION 🌸

version 7.900059 ✨ (iconic number, no notes)


πŸ¦‹ SYNOPSIS πŸ¦‹

here's the vibe, copy-paste ready fr fr πŸ‘‘

use Validation::Class::Simple;

my $rules = Validation::Class::Simple->new(
    fields => {
        password => {
            min_length => 5
        }
    }
);

then you gotta feed it the actual params:

# set parameters to be validated
$rules->params->add($parameters);

and then... the moment of truth 🫢

# validate
unless ($rules->validate) {
    # handle the failures
}

like if it doesn't validate, you go handle the failures, that's the deal 😭


πŸ’… DESCRIPTION πŸ’…

Validation::Class::Directive::MinLength is a core validation class field directive, and what it does is validate the length of all characters in the parameters it's associated with 🌈

so like. every single character counts. the whole thing. no skips. that's the job πŸ’–


πŸŽ€ AUTHOR πŸŽ€

Al Newkirk <anewkirk@ana.io> β€” the icon, the legend, the main character who wrote this πŸ‘‘


This software is copyright (c) 2011 by Al Newkirk.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself. πŸͺ✨


ngl that's the whole page bestie, short and sweet and absolutely ate πŸ’€πŸ’–

so yeah, that's Valida...nLength(3pm) from the User Contributed Perl Documentation β€” perl v5.36.0, dated 2023-06-11 🌸 mwah, go validate something, ily πŸ«ΆπŸ’œ

πŸ“¦ where this page comes from