Skip to content

Handling validation and casting of ISBN in Laravel Eloquent models.

License

Notifications You must be signed in to change notification settings

legalworks/laravel-isbn-tools

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

legalworks/laravel-isbn-tools

Latest Version on Packagist Total Downloads License

This package allows casting and validation of ISBN in Laravel Eloquent models, using the nicebooks/isbn-library.

Installation

Via Composer

$ composer require legalworks/laravel-isbn-tools

Usage

Casting

use Legalworks\IsbnTools\IsbnCast;

protected $casts = [
    'isbn' => IsbnCast::class,
];

Validation

use Legalworks\IsbnTools\IsbnValidator;

$request->validate([
    'isbn' => ['required', 'string', new IsbnValidator],
]);

Change log

Please see the changelog for more information on what has changed recently.

Testing

$ composer test

Contributing

Please see contributing.md for details and a todolist.

Security

If you discover any security related issues, please email author email instead of using the issue tracker.

Credits

License

license. Please see the license file for more information.

About

Handling validation and casting of ISBN in Laravel Eloquent models.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages