From 625dbb5eb322422ccc13b5916024e8db0b826bcc Mon Sep 17 00:00:00 2001 From: Brian Dillingham Date: Fri, 11 Jan 2019 14:37:19 -0500 Subject: [PATCH] add validation docs --- readme.md | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/readme.md b/readme.md index af7e518..892a844 100644 --- a/readme.md +++ b/readme.md @@ -35,6 +35,17 @@ Items::make('Emails')->values($this->emails), | **deleteButtonValue(html)** | value for delete button | No | "x" | | **createButtonValue(html)** | value for create button | No | "Add" | +### Validation + +```php + +Items::make('Emails')->values($this->emails)->rules([ + 'emails.*' => 'email|min:10', +]), +``` + +![validation](https://user-images.githubusercontent.com/29180903/51055617-54a36d00-15ae-11e9-86d2-b8a2b14e5d5a.png) + ### Sidenotes