flrx_validator 0.2.0 flrx_validator: ^0.2.0 copied to clipboard
A powerful, extensible validator package to get validation messages based on a list of rules.
Use this package as a library
Depend on it
Run this command:
With Dart:
$ dart pub add flrx_validator
This will add a line like this to your package's pubspec.yaml (and run an implicit dart pub get
):
dependencies:
flrx_validator: ^0.2.0
Alternatively, your editor might support dart pub get
. Check the docs for your editor to learn more.
Import it
Now in your Dart code, you can use:
import 'package:flrx_validator/rule.dart';
import 'package:flrx_validator/rules/any_rule.dart';
import 'package:flrx_validator/rules/email_rule.dart';
import 'package:flrx_validator/rules/max_length_rule.dart';
import 'package:flrx_validator/rules/min_length_rule.dart';
import 'package:flrx_validator/rules/one_of_rule.dart';
import 'package:flrx_validator/rules/regex_rule.dart';
import 'package:flrx_validator/rules/required_rule.dart';
import 'package:flrx_validator/validator.dart';