codelayer / laravel-vat-validator
Validate the format of EU vat numbers.
Installs: 8 943
Dependents: 0
Suggesters: 0
Security: 0
Stars: 3
Watchers: 4
Forks: 2
Open Issues: 1
Requires
- php: ^7.2
- ext-json: *
- illuminate/support: ^5.8|^6.0|^7.0
Requires (Dev)
- phpunit/phpunit: ~8.0
This package is auto-updated.
Last update: 2024-11-10 22:38:20 UTC
README
This package can be used to validate EU VAT identification numbers such as DE123456789
.
You can install the package using composer:
composer require codelayer/laravel-vat-validator
Translations
If you wish to customize the package's translation, you can publish the translation files:
php artisan vendor:publish --provider="Codelayer\VatValidator\VatValidatorServiceProvider"
Usage
Simply use the VatFormat
rule inside your rules array, e.g. in a form request:
use Codelayer\VatValidator\Rules\VatFormat; public function rules() { return [ 'vat_number' => ['required', new VatFormat()], ]; }
About Us
codelayer is a web development agency based in Karlsruhe, Germany. This package was developed for use in our product likvi.
License
The MIT License (MIT).