W3cubDocs

/Angular 4 TypeScript

NgControl

Stable Class

Class Overview

class NgControl extends AbstractControlDirective {
  name : string
  valueAccessor : ControlValueAccessor
  validator : ValidatorFn
  asyncValidator : AsyncValidatorFn
  viewToModelUpdate(newValue: any) : void
}

Class Description

A base class that all control directive extend. It binds a FormControl object to a DOM element.

Used internally by Angular forms.

Class Details

name : string
valueAccessor : ControlValueAccessor
validator : ValidatorFn
asyncValidator : AsyncValidatorFn
viewToModelUpdate(newValue: any) : void

exported from forms/index, defined in forms/src/directives/ng_control.ts

© 2010–2017 Google, Inc.
Licensed under the Creative Commons Attribution License 4.0.
https://angular.io/docs/ts/latest/api/forms/index/NgControl-class.html