tanthammar / laravel-rules
Custom validation rules for the Laravel Framework
3.2.0
2024-03-14 10:59 UTC
Requires
- php: ^8.1|^8.2|^8.3
- brick/phonenumber: ^0.6.0
- byrokrat/banking: ^2.2
- laravel/framework: ^9.0|^10.0|^11.0
- mpociot/vat-calculator: ^3.0
- organisationsnummer/organisationsnummer: ^1.0.0
- personnummer/personnummer: ^3.0.4
- spatie/laravel-package-tools: ^1.9.2
- tanthammar/laravel-extras: dev-master
README
In this repository I will add validators and factory helpers, that I use in my SaaS app. I think especially Swedish developers will find them handy.
Requirements
- PHP 8.1
- Laravel v9.0
Installation
composer require tanthammar/laravel-rules
Rules, Fakers and more
See src folder
Documentation
There won't be much documentation written, this repository will grow as I add items. Hopefully the source code contains enough hints to use the components.
They are all used in the same way, following Laravel conventions.
Example:
use TantHammar\LaravelRules\Rules\PhoneNumber; use TantHammar\LaravelRules\Rules\PersonNummer; SomeField::make('phone') ->rules([ new PhoneNumber ]) SomeField::make('person_nummer') ->rules([ new PersonNummer ])