{"action":"closed","issue":{"url":"https://api.github.com/repos/bvaughn/angular-form-for/issues/148","labels_url":"https://api.github.com/repos/bvaughn/angular-form-for/issues/148/labels{/name}","comments_url":"https://api.github.com/repos/bvaughn/angular-form-for/issues/148/comments","events_url":"https://api.github.com/repos/bvaughn/angular-form-for/issues/148/events","html_url":"https://github.com/bvaughn/angular-form-for/issues/148","id":97801940,"number":148,"title":"Feature request: never validate not-required blank/empty/unchecked inputs","user":{"login":"indrimuska","id":1561134,"avatar_url":"https://avatars.githubusercontent.com/u/1561134?v=3","gravatar_id":"","url":"https://api.github.com/users/indrimuska","html_url":"https://github.com/indrimuska","followers_url":"https://api.github.com/users/indrimuska/followers","following_url":"https://api.github.com/users/indrimuska/following{/other_user}","gists_url":"https://api.github.com/users/indrimuska/gists{/gist_id}","starred_url":"https://api.github.com/users/indrimuska/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/indrimuska/subscriptions","organizations_url":"https://api.github.com/users/indrimuska/orgs","repos_url":"https://api.github.com/users/indrimuska/repos","events_url":"https://api.github.com/users/indrimuska/events{/privacy}","received_events_url":"https://api.github.com/users/indrimuska/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/bvaughn/angular-form-for/labels/enhancement","name":"enhancement","color":"84b6eb"}],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-07-28T21:04:58Z","updated_at":"2015-07-29T04:08:24Z","closed_at":"2015-07-29T04:08:24Z","body":"Every time an input is set to **not-required**, I would expect the plugin doesn't validate the field when it is blank (empty) even if it has a custom validator.\r\n\r\nLet me make the problem clear.\r\n\r\nLet's have a simple email input that accepts only gmail accounts ([plunker](http://plnkr.co/edit/w9kqIQa6U1cESUVBsJNr?p=preview)):\r\n```javascript\r\nemail: {\r\n   inputType: 'text',\r\n   placeholder: 'please, provide a gmail account',\r\n   required: false,\r\n   pattern: /\\w+@gmail\\.com$/\r\n}\r\n```\r\nIf I leave the input blank and I try to submit the form, the plugin prevents submission and shows the classic **Invalid format** error.\r\n\r\n![schermata 2015-07-28 alle 22 58 23](https://cloud.githubusercontent.com/assets/1561134/8943816/fdbd428c-357c-11e5-84c4-9d3f9eedeb28.png)\r\n\r\nThe question I made when I see that was: **why?** The input is not-required, so why the plugin validates it? As a normal HTML5 email input (with no `required` attribute) is not \"processed\" by the browser (or by Angular) when I leave it blank, the same I expect from this plugin."}}