93 lines
1.3 KiB
Plaintext
93 lines
1.3 KiB
Plaintext
|
|
p.location-badge.
|
|
exported from <a href='../forms'>angular2/forms</a>
|
|
defined in <a href="https://github.com/angular/angular/tree/master/modules/angular2/src/forms/directives/select_control_value_accessor.ts#L4-L41">angular2/src/forms/directives/select_control_value_accessor.ts (line 4)</a>
|
|
|
|
:markdown
|
|
The accessor for writing a value and listening to changes that is used by a
|
|
<a href='Control-class.html'><code>Control</code></a> directive.
|
|
|
|
This is the default strategy that Angular uses when no other accessor is applied.
|
|
|
|
# Example
|
|
```
|
|
<input type="text" [control]="loginControl">
|
|
```
|
|
|
|
.l-main-section
|
|
h2 Members
|
|
.l-sub-section
|
|
h3 constructor
|
|
|
|
|
|
pre.prettyprint
|
|
code.
|
|
constructor(cd: ControlDirective, private _elementRef: ElementRef, private _renderer: Renderer)
|
|
|
|
:markdown
|
|
|
|
|
|
|
|
|
|
|
|
|
|
.l-sub-section
|
|
h3 onChange
|
|
|
|
|
|
:markdown
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
.l-sub-section
|
|
h3 registerOnChange
|
|
|
|
|
|
pre.prettyprint
|
|
code.
|
|
registerOnChange(fn)
|
|
|
|
:markdown
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
.l-sub-section
|
|
h3 value
|
|
|
|
|
|
:markdown
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
.l-sub-section
|
|
h3 writeValue
|
|
|
|
|
|
pre.prettyprint
|
|
code.
|
|
writeValue(value)
|
|
|
|
:markdown
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|