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

konami-kickass

v1.0.0

Published

Listen for the Konami code, then unleash the KickAss game overlay on any page.

Downloads

33

Readme

konami-kickass

Listen for the Konami code (↑ ↑ ↓ ↓ ← → ← → B A) and, once entered, unleash the KickAss game overlay on any page.

Install

npm install konami-kickass

Usage

import { listenForKonami } from "konami-kickass";

// Start listening. Enter the Konami code to launch KickAss.
listenForKonami();

With options:

import { listenForKonami } from "konami-kickass";

const listener = listenForKonami({
  repeat: true, // keep listening after activation
  onActivate() {
    console.log("KickAss launched!");
  },
});

// Later, stop listening:
listener.destroy();

You can also trigger it manually:

import { launchKickass } from "konami-kickass";

launchKickass();

Script tag

If you are not using a bundler, build then drop the ESM bundle into a module script:

<script type="module">
  import { listenForKonami } from "./dist/konami-kickass.js";
  listenForKonami();
</script>

Demo

A standalone page lives in examples/demo/:

npm run demo   # builds, then serves on http://localhost:8899

Open http://localhost:8899/examples/demo/ and type the Konami code. An on-screen meter tracks progress; entering the full sequence launches the game. Uncomment the assetBase line in the demo to test a proxy.

API

listenForKonami(options?)

Attaches a keydown listener and calls launchKickass() once the sequence is entered. Returns a { destroy() } handle.

| Option | Type | Default | Description | | ------------ | ------------------------ | -------------------------- | -------------------------------------------------- | | target | Window \| HTMLElement | window | Element to attach the listener to. | | sequence | string[] | Konami code | Custom key sequence (KeyboardEvent.key values). | | repeat | boolean | false | Keep listening after the first activation. | | assetBase | string | https://kickassapp.com/ | Proxy base for KickAss's own runtime assets. | | onActivate | () => void | — | Called right after KickAss launches. |

launchKickass(assetBase?)

Injects the bundled KickAss source into the page inline (no remote script fetch). Safe to call in non-DOM environments (no-op) and only injects once. Pass assetBase to proxy KickAss's runtime requests (see below).

Proxying KickAss's runtime requests

Bundling the script removes the fetch of kickass.js itself, but KickAss still loads its own assets at runtime — CSS, sprites, sounds, api.json, and postMessage iframes — all from a single base URL (https://kickassapp.com/).

That base is configurable. Point it at your own proxy:

import { listenForKonami } from "konami-kickass";

listenForKonami({
  assetBase: "https://your-proxy.example/kickass/",
});

or directly:

import { launchKickass } from "konami-kickass";

launchKickass("https://your-proxy.example/kickass/");

Your proxy must forward requests to https://kickassapp.com/ and preserve paths (e.g. /css/menustyles.css, /static/sounds/game/shot.mp3, /mysite/api.json, /hello.html). Notes:

  • The base must end with a trailing slash.
  • Iframe messaging uses this base as its postMessage origin, so the proxy origin must serve hello.html / intermediate_postmessage.html for the socket features to work.
  • To fully self-host, mirror the kickassapp.com asset tree behind your proxy.

Ready-made proxies (Cloudflare Worker + Express) live in examples/proxy/ — deploy one and use its URL as assetBase.

How it works

It reproduces this bookmarklet, gated behind the Konami code — except the KickAss source is vendored into the package (src/kickass.vendor.js) and injected inline instead of loaded from a remote URL:

var KICKASSVERSION = "2.0";
var s = document.createElement("script");
s.type = "text/javascript";
s.text = /* bundled kickass.js source */;
document.body.appendChild(s);

Note: KickAss itself still makes its own network requests at runtime — see Proxying KickAss's runtime requests to route those. To refresh the vendored copy, replace src/kickass.vendor.js and rebuild.

License

MIT