custom-control
v1.0.3
Published
The library enabling two way data binding with formating. Validation based on the type of format of input.
Downloads
18
Maintainers
Readme
Custom-Control
The library enabling two way data binding with formating. Validation based on the type of format of input.
Quick links
Demo | StackBlitz example | Documentation
Installing and usage
npm install custom-control --save
Load the module for your app:
import { CustomControlModule } from 'custom-control';
@NgModule({
...
imports: [
...
CustomControlModule
]
})
Use it in component:
input = {
name: 'Number Field - 2 decimal places',
value: 452354,
format: 'number',
places: '2',
readOnly: false
};
culture = 'en-US';
<c-input class="input-fields"
[(model)]="input.value"
[format]="input.format"
[places]="input.places"
[readOnly]="input.readOnly"
[culture]="culture"
(modelChange)="dataChange($event, input.value)">
</c-input>