ngx-enter-key
TypeScript icon, indicating that this package has built-in type declarations

1.1.0 • Public • Published

Build Status npm version License: MIT

ngx-enter-key

Does not trigger enter key pressed during composing input.

Installation

npm install --save ngx-enter-key

Usage

import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { NgxEnterKeyModule } from 'ngx-enter-key';

import { AppComponent } from './app.component';

@NgModule({
    imports: [
        BrowserModule,
        NgxEnterKeyModule
    ],
    declarations: [AppComponent],
    bootstrap: [AppComponent]
})
export class AppModule {}
@Component({
  selector: 'app-form',
  template: `
  <input (ngxEnterKey)="onEnterKey($event)">
  `
})
export class FormComponent {

  onEnterKey(event: KeyboardEvent) {
    console.log(event);
  }

}

Dependencies (1)

Dev Dependencies (0)

    Package Sidebar

    Install

    npm i ngx-enter-key

    Weekly Downloads

    2

    Version

    1.1.0

    License

    MIT

    Unpacked Size

    40.8 kB

    Total Files

    24

    Last publish

    Collaborators

    • itigoore01