X Tutup
Skip to content

feat(forms): add support for adding async validators via template#5020

Closed
vsavkin wants to merge 4 commits intoangular:masterfrom
vsavkin:forms_async_validations_2
Closed

feat(forms): add support for adding async validators via template#5020
vsavkin wants to merge 4 commits intoangular:masterfrom
vsavkin:forms_async_validations_2

Conversation

@vsavkin
Copy link
Copy Markdown
Contributor

@vsavkin vsavkin commented Oct 30, 2015

Example:

@Directive({
  selector: '[uniq-login-validator]',
  providers: [provide(NG_ASYNC_VALIDATORS, {useExisting: UniqLoginValidator, multi: true})]
})
class UniqLoginValidator implements Validator {
  validate(c) { return someFunctionReturningPromiseOrObservable(); }
}

@vsavkin vsavkin added the action: review The PR is still awaiting reviews from at least one requested reviewer label Oct 30, 2015
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: could you update the ctor signature and drop this line ?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed

@vicb
Copy link
Copy Markdown
Contributor

vicb commented Oct 30, 2015

LGTM

Example:

@directive({
  selector: '[uniq-login-validator]',
  providers: [provide(NG_ASYNC_VALIDATORS, {useExisting: UniqLoginValidator, multi: true})]
})
class UniqLoginValidator implements Validator {
  validate(c) { return someFunctionReturningPromiseOrObservable(); }
}
@vsavkin vsavkin force-pushed the forms_async_validations_2 branch from a6596f9 to 3a4bf3e Compare November 2, 2015 18:01
@vsavkin vsavkin added the action: merge The PR is ready for merge by the caretaker label Nov 2, 2015
@mary-poppins
Copy link
Copy Markdown

Merging PR #5020 on behalf of @vsavkin to branch presubmit-vsavkin-pr-5020.

@mary-poppins mary-poppins removed the action: merge The PR is ready for merge by the caretaker label Nov 2, 2015
@vsavkin vsavkin closed this in 1c322f1 Nov 2, 2015
@dimitrikochnev dimitrikochnev mentioned this pull request Nov 20, 2015
@angular-automatic-lock-bot
Copy link
Copy Markdown

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 7, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

action: review The PR is still awaiting reviews from at least one requested reviewer cla: yes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants

X Tutup