This library was inspired by the useKonamiCode hook.
npm install konami-key
Simply import the module and you're done:
import { BrowserModule } from '@angular/platform-browser';
import { NgModule } from '@angular/core';
import { AppRoutingModule } from './app-routing.module';
import { AppComponent } from './app.component';
import { KonamiKeyModule } from 'konami-key';
@NgModule({
declarations: [
AppComponent
],
imports: [
BrowserModule,
AppRoutingModule,
KonamiKeyModule
],
providers: [],
bootstrap: [AppComponent]
})
export class AppModule { }
Open your page and fire the Konami Code (↑ ↑ ↓ ↓ ← → ← → B A)!