npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@phalgunv/ngx-keyboard-shortcuts

v21.0.1

Published

Keyboard-shortcuts for creating and implementing keyboard events in Angular apps.

Downloads

6,847

Readme

@phalgunv/ngx-keyboard-shortcuts

⚠️ Maintained Fork: This is an actively maintained fork of the original ngx-keyboard-shortcuts package (now archived). This fork adds Angular 16+, 17+, 18+, 19+, 20+, and 21+ support with modern tooling.

npm version

By using simple directives ngx-keyboard-shortcuts allows you to create and implement custom keybindings events in your Angular applications.

Versioning

This package follows Angular's major version numbering:

  • v16.x.x - Compatible with Angular 16+
  • v17.x.x - Compatible with Angular 17+
  • v18.x.x - Compatible with Angular 18+
  • v19.x.x - Compatible with Angular 19+
  • v20.x.x - Compatible with Angular 20+
  • v21.x.x - Compatible with Angular 21+

This makes it easy to identify which version supports your Angular version.

Requirements

  • Angular: 21+ (for v21.x), 20+ (for v20.x), 19+ (for v19.x), 18+ (for v18.x), 17+ (for v17.x), 16+ (for v16.x)
  • Node.js: 20.0+
  • TypeScript: 5.6.x (for v21.x, v20.x, and v19.x), 5.5.x (for v18.x), 5.4.x (for v17.x), 5.1.x (for v16.x)

Note: For Angular 10-15, use v1.x of the original package.

Installation

## Installation

```bash
npm install @phalgunv/ngx-keyboard-shortcuts --save

Quick Start

Example:

<button [keyboardShortcut]="keyboardShortcutDef" (click)="save()">
    Save
</button>
keyboardShortcutDef: IKeyboardShortcutListenerOptions = {
    description: 'save',
    keyBinding: [KeyboardKeys.Ctrl, KeyboardKeys.Shift, 's']
};

Usage

import { NgModule } from '@angular/core';
import { BrowserModule } from '@angular/platform-browser';
import { NgxKeyboardShortcutModule } from '@phalgunv/ngx-keyboard-shortcuts';

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

@NgModule({
  declarations: [AppComponent],
  imports: [
    BrowserModule,
    NgxKeyboardShortcutModule.forRoot()
  ],
  providers: [],
  bootstrap: [AppComponent]
})
export class AppModule { }

Demos

see the demo site https://milestechnologies.github.io/ngx-keyboard-shortcuts

Contributing

Development Setup

npm install
npm start  # Run the demo environment

Testing and Linting

npm test        # Run Jest tests
npm run lint    # Run ESLint

Building

npm run build   # Build the library package

Built With

Version

21.0.0

Migration from v1.x

If you're upgrading from v1.x:

  • Angular 21+ is now required
  • Node.js 20+ is required
  • Peer dependencies updated to @angular/core and @angular/common ^21.0.0

For detailed migration information, see CHANGELOG.md.

Contributors

Thank you to the contributors of this package.

License

This project is licensed under the MIT License - see the LICENSE.md file for details.