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

automatic validation

Adam Radabaugh edited this page Feb 10, 2015 · 2 revisions

How can I disable automatic validations?

The most frequent request is how does one disable a model from automatically validating?

Don't.

Why?

The concern with the automatic validations are usually around the displaying of the errors not necessarily the running of the errors. ember-validations is correct to automatically run the validations on init.

View-layer libraries like ember-easy-form will properly defer the displaying of errors until after a given input is interacted with or the form submission is attempted. However you are displaying your errors you should consider a similar approach:

{{#if displayErrors}}
  {{model.errors.firstName}}
{{/if}}
Clone this wiki locally