Skip to content

Firing validations only when some DOM event type occurs #33

Description

@nasdan

We would like to consume navite DOM event types and it only fires desired validations on that events.

Somethink like:

const validationSchema: ValidationSchema = {
  field: {
    login: [
      // fire validation only for change and blur events
      { validator: Validators.required.validator, events: ['change', 'blur'] }
    ],
    password: [
      // Fire validations for any event
      { validator: Validators.required.validator }
    ],
  }
}

DOM typings: search GlobalEventHandlersEventMap inside file.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions