ikromjon1998/laravel-german-license-plate-validator

A Laravel package that provides a custom validation rule to verify the format of German license plate numbers, ensuring compliance with standard German license plate conventions.

v1.0.9 2025-01-07 08:39 UTC

This package is not auto-updated.

Last update: 2025-08-19 17:43:13 UTC


README

A Laravel package to validate German license plate numbers.

Installation

Install via Composer:

composer require ikromjon1998/german-license-validator

Usage

Use the custom validation rule in your Laravel validators:

$request->validate([
    'license_plate' => 'required|german_license_plate',
]);

Configuration

You can publish the configuration file to customize the regex or error messages:

php artisan vendor:publish --tag=config

The configuration file will be published to config/license-plate.php.

Testing

Run tests with PHPUnit:

vendor/bin/phpunit