1.0.0 • Published 5 years ago
ngx-ipv4-helper v1.0.0
ngx-ipv4-helper
An angular directive to help input ipv4 address
Installation
To install this library, run:
$ npm install ngx-ipv4-helper --saveand then import module:
import { BrowserModule } from "@angular/platform-browser";
import { NgModule } from "@angular/core";
import { AppComponent } from "./app.component";
import { NgxIpv4HelperModule } from "ngx-ipv4-helper"; // <===
@NgModule({
declarations: [AppComponent],
imports: [
BrowserModule,
NgxIpv4HelperModule, // <===
],
providers: [],
bootstrap: [AppComponent],
})
export class AppModule {}Usage
ngxIpv4Helper should place on input with ngControl
Template form
<input ngModel ngxIpv4Helper />Reactive form
<input [formControl]="ip" ngxIpv4Helper />ip = new FormControl("");1.0.0
5 years ago