How to use ngx-valdemort - 2 common examples

To help you get started, we’ve selected a few ngx-valdemort examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github Ninja-Squad / ngx-valdemort / projects / demo / src / app / integration / material / material.component.ts View on Github external
constructor(config: ValdemortConfig, fb: FormBuilder) {
    config.displayMode = DisplayMode.ONE;
    config.shouldDisplayErrors = () => true;

    this.form = fb.group({
      email: ['', [Validators.required, Validators.email]],
      age: [null, [Validators.required, Validators.min(18)]]
    });
  }
github Ninja-Squad / ngx-valdemort / projects / demo / src / app / configuration / configuration.component.ts View on Github external
constructor(config: ValdemortConfig, fb: FormBuilder) {
    config.errorsClasses = 'text-warning';
    config.displayMode = DisplayMode.ONE;
    config.shouldDisplayErrors = (control, form) => control.dirty;

    this.form = fb.group({
      email: ['', [Validators.required, Validators.email]],
      age: [null, [Validators.required, Validators.min(18)]]
    });
  }

ngx-valdemort

Simple, consistent validation error messages for your Angular forms

MIT
Latest version published 2 months ago

Package Health Score

72 / 100
Full package analysis

Popular ngx-valdemort functions