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

@ctrlk/core

v2.1.0

Published

The first IOUX (Integrated Operational UX) for enterprise web apps

Downloads

724

Readme

CtrlK

The first IOUX for enterprise web apps.

CtrlK is a headless interaction engine that adds commands, keyboard shortcuts, saved views, field navigation, macros, and shareable state to any enterprise web application. It provides the logic — your app provides the UI using your own framework and design system.

An IOUX (Integrated Operational UX) is to application operators what an IDE is to developers.

npm License: MIT Tests


How It Works

CtrlK is headless — zero DOM, zero styles. When a shortcut fires, the engine emits an event. Your app catches it and renders its own component.

import ctrlk from '@ctrlk/core';

ctrlk.init({ palette: true, density: true });

// Register commands
ctrlk.commands.register({
  id: 'deals.refresh',
  title: 'Refresh Deals',
  shortcut: 'Ctrl+R',
  category: 'Deals',
  execute: () => refreshGrid(),
});

// When Ctrl+K fires — YOUR app renders YOUR palette component
ctrlk.onPaletteRequest(({ commands, search, execute }) => {
  openMyPaletteDialog({ commands, search, execute });
});

// When Ctrl+G fires — YOUR app renders YOUR field search
ctrlk.onFieldJumpRequest(({ fields, search, focus }) => {
  openMyFieldJumpDialog({ fields, search, focus });
});

Install

npm install @ctrlk/core

# Grid adapters
npm install @ctrlk/ag-grid      # AG Grid v28-31+
npm install @ctrlk/devextreme   # DevExtreme v21+

# Framework adapters
npm install @ctrlk/react        # React hooks
npm install @ctrlk/angular      # Angular service + directives

Framework Integration

Angular + DevExtreme

import { Injectable, NgZone } from '@angular/core';
import ctrlk from '@ctrlk/core';
import { DevExtremeAdapter } from '@ctrlk/devextreme';
import { Subject } from 'rxjs';

@Injectable({ providedIn: 'root' })
export class CtrlkService {
  readonly paletteRequested$ = new Subject();

  init() {
    ctrlk.init({ palette: true, density: true });
    ctrlk.onPaletteRequest((req) => this.paletteRequested$.next(req));
  }

  bridgeGrid(gridInstance, keyExpr = 'id') {
    ctrlk.connectGrid(new DevExtremeAdapter(gridInstance, { keyExpr }));
  }
}

React

import ctrlk from '@ctrlk/core';
import { useEffect, useState } from 'react';

function useCtrlkPalette() {
  const [open, setOpen] = useState(false);
  const [request, setRequest] = useState(null);

  useEffect(() => {
    return ctrlk.onPaletteRequest((req) => {
      setRequest(req);
      setOpen(true);
    });
  }, []);

  return { open, request, close: () => setOpen(false) };
}

Vue 3

import { ref, onMounted, onUnmounted } from 'vue';
import ctrlk from '@ctrlk/core';

export function useCtrlkPalette() {
  const open = ref(false);
  const request = ref(null);
  let unsub;

  onMounted(() => {
    unsub = ctrlk.onPaletteRequest((req) => {
      request.value = req;
      open.value = true;
    });
  });
  onUnmounted(() => unsub?.());

  return { open, request, close: () => (open.value = false) };
}

What's Inside

19 modules. 150 tests. Zero dependencies. 125 KB minified.

Engine

| Module | Purpose | |--------|---------| | CommandRegistry | Register, search, and execute commands | | ShortcutEngine | Scope-aware keyboard shortcuts with chord support | | ViewStateManager | Save, load, share named view configurations (LRU, slots) | | FieldRegistry | Field-level search, focus, dirty tracking, completeness | | SelectionModel | Cross-page persistent selections with set operations | | DensityController | Compact / comfortable / spacious via CSS custom properties | | MacroEngine | Record and replay command sequences | | HistoryManager | Application-level undo/redo |

Navigation

| Module | Purpose | |--------|---------| | ColumnNavigator | Column search, bookmarks, horizontal jump | | FocusNavigator | F6 zone navigation between UI areas | | SessionTracker | Batch review progress tracking |

Sharing

| Module | Purpose | |--------|---------| | ViewShare | Shareable view links via URL encoding, stored sharing, live sharing |

Grid Adapters

| Library | Package | Lines | |---------|---------|-------| | AG Grid v28-31+ | @ctrlk/ag-grid | 670 | | DevExtreme v21+ | @ctrlk/devextreme | 977 |

The DevExtreme adapter includes grouping, summary, master-detail, and batch editing support beyond the standard GridAdapter interface.

Event Hooks

| Hook | Fires When | Payload | |------|-----------|---------| | onPaletteRequest(cb) | Ctrl+K pressed | { commands, search(q), execute(id) } | | onFieldJumpRequest(cb) | Ctrl+G pressed | { fields, search(q), focus(id) } | | onShortcutsRequest(cb) | Ctrl+/ pressed | { shortcuts } | | onDensityChange(cb) | Density cycles | { level, previous } | | onViewSaved(cb) | View saved | { name, slot, shortcut } | | onViewLoaded(cb) | View loaded | { name } | | onCommandExecuted(cb) | Command runs | { id, result } |

Each returns an unsubscribe function.

Default Shortcuts

| Shortcut | Action | |----------|--------| | Ctrl+K | Palette request | | Ctrl+G | Field jump request | | Ctrl+D | Cycle density | | Ctrl+1Ctrl+5 | Load saved view by slot | | Ctrl+Shift+S | Share current view | | Ctrl+/ | Shortcuts request | | Ctrl+Z / Ctrl+Y | Undo / Redo |

All shortcuts are customizable.

Documentation

License

MIT — Created by Prabhu Raja