MCPcopy Create free account
hub / github.com/angular/angular / InitValidatingFvcInput

Class InitValidatingFvcInput

packages/forms/signals/test/web/reactive_fvc.spec.ts:1379–1398  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1377}
1378
1379@Component({
1380 selector: 'init-validating-fvc-input',
1381 template: '',
1382 providers: [
1383 {provide: NG_VALIDATORS, useExisting: forwardRef(() => InitValidatingFvcInput), multi: true},
1384 ],
1385})
1386class InitValidatingFvcInput implements OnInit, Validator {
1387 readonly value = model('');
1388 readonly errors = input<readonly any[]>([]);
1389 private validator?: ValidatorFn;
1390
1391 ngOnInit(): void {
1392 this.validator = Validators.minLength(3);
1393 }
1394
1395 validate(control: AbstractControl): ValidationErrors | null {
1396 return this.validator!(control);
1397 }
1398}
1399
1400@Component({
1401 selector: 'fvc-checkbox',

Callers

nothing calls this directly

Calls 2

ComponentInterface · 0.90
forwardRefFunction · 0.90

Tested by

no test coverage detected