title: Custom Validation TextFormField Flutter
body: <p>I have Form and TextFormField inside it :</p>
  
  <pre><code> new Expanded(
    child: TextFormField(
      style: new TextStyle(color: Colors.white),
      keyboardType: TextInputType.text,
      validator: (String value) {
        if (value.length &lt;= 5) {
         //Show error as a Snackbar
        }
      },
      onSaved: (String value) {},
  
    ),
  )
  </code></pre>
  
  <p>On a Buttom press I am checking if all the fields are validate :</p>
  
  <pre><code> if (_formKey.currentState.validate()) {
        _submit();
   }
  </code></pre>
  
  <p>Now the issue is when you call <code>validate()</code> and don't return any text in <code>validate()</code> method then it will consider it return true.</p>
  
  <p>I don't want to show error below the textField but as a Snackbar.</p>
  
  <p>Also, I tried setting an extra flag and setting in each validator Method but it gets complex if there are multiple fields in the form.</p>
  
  <p>Can anyone tell me how can I handle this situation where <code>_formKey.currentState.validate()</code> should return false and validator method
  inside TextFormField need not to return error text.</p>