ng-bootstrap-form-validation icon indicating copy to clipboard operation
ng-bootstrap-form-validation copied to clipboard

exportAs

Open kryxie opened this issue 6 years ago • 2 comments

Validating from code.

template <form [formGroup]="deviceForm" #deviceFormRef="ngFormValidator">

.ts `@ViewChild('deviceFormRef') deviceFormRef: FormValidationDirective;

public onSubmit(): void { this.deviceFormRef.onSubmit(); }

`

kryxie avatar Apr 29 '19 14:04 kryxie

Rather than ngFormValidator, should this be something like ngBootstrapFormValidator to be more namespaced to the package?

third774 avatar Apr 29 '19 15:04 third774

Thinking about this a bit more and feeling like the onSubmit handler shouldn't be callable by library consumers. Perhaps the code within that handler should be pulled out into a public method and the onSubmit handler should be private. Thoughts?

third774 avatar May 05 '19 03:05 third774