Skip to content
This repository has been archived by the owner on May 29, 2019. It is now read-only.

datepicker $setValidity $error does not follow convention naming #2773

Closed
emouawad opened this issue Oct 2, 2014 · 1 comment
Closed

datepicker $setValidity $error does not follow convention naming #2773

emouawad opened this issue Oct 2, 2014 · 1 comment

Comments

@emouawad
Copy link

emouawad commented Oct 2, 2014

In datepicker.js
ngModelCtrl.$setValidity('date-disabled', !date || (this.element && !this.isDisabled(date)));

$setValidity(validationErrorKey, isValid)
validationErrorKey: does not follow convention

The validationErrorKey should be in camelCase and will get converted into dash-case for class name. Example: myError will result in ng-valid-my-error and ng-invalid-my-error class and can be bound to as {{someForm.someControl.$error.myError}} .

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants