MCPcopy Index your code
hub / github.com/crittermike/shortkeys

github.com/crittermike/shortkeys @v5.0.1

Chat with this repo
repository ↗ · DeepWiki ↗ · release v5.0.1 ↗ · + Follow
236 symbols 629 edges 72 files 34 documented · 14%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Shortkeys logo

Shortkeys

Custom keyboard shortcuts for your browser

A cross-browser extension for Chrome, Firefox, Edge, and Opera with 200,000+ Chrome users.

Chrome Web Store · Firefox Add-ons · Website · Issues

Shortkeys options page

Features

  • 125+ built-in actions across 11 categories: scrolling, tabs, navigation, video controls, search, bookmarks, windows, zooming, page tools, page scripts, and more
  • 🔍 Command palette - click the icon or set a shortcut to search and trigger any action
  • 📦 9 curated shortcut packs - one-click install for Vim, Emacs, YouTube, Productivity, Developer, Reading, Tab Manager, Keyboard Power, and Media Control
  • ☁️ Cloud sync with automatic local fallback when data exceeds sync quota
  • 📁 Groups - organize shortcuts into collapsible, renamable sections with bulk enable/disable
  • 🔗 Macro chaining - chain multiple actions into a single shortcut
  • 🌐 Site filtering - all sites, blocklist, or allowlist per shortcut
  • 🎬 Live reload - shortcuts update in all tabs instantly, no page refresh needed
  • 🔗 Shareable links - generate a URL to share shortcuts or groups with anyone
  • ⌨️ Shortcut recorder with multi-key sequence support (e.g. g i, g h)
  • ⚠️ Conflict detection - platform-aware warnings for browser default clashes
  • 🌙 Dark mode following system preference
  • 📜 Userscript import from Greasyfork and OpenUserJS
  • 🧙 Guided onboarding wizard for new users
  • ↩️ Undo/redo in the settings page

More screenshots

Custom JavaScript editor

Custom JavaScript editor

Macro chaining

Macro chaining

Dark mode

Dark mode

Install

Chrome Chrome Firefox Firefox Edge Edge Opera Opera

Or build from source:

npm install
npm run build          # Chrome → .output/chrome-mv3/
npm run build:firefox  # Firefox → .output/firefox-mv2/

Development

npm run dev            # Chrome dev mode with hot reload
npm run dev:firefox    # Firefox dev mode
npm test               # Run all tests (722 tests across 25 files)
npm run test:watch     # Watch mode
npm run test:coverage  # With coverage report

Project structure

src/
├── entrypoints/
│   ├── background.ts        # Service worker: messaging, action dispatch, storage sync
│   ├── content.ts           # Content script: Mousetrap key bindings, cheat sheet, dark mode
│   ├── options/             # Options page (Vue 3 SPA)
│   └── popup/               # Command palette popup
├── actions/                 # Action handlers and helpers
├── components/              # Vue components (CodeEditor, SearchSelect, ShortcutRecorder)
├── composables/             # Vue composables (useShortcuts)
├── packs/                   # 9 curated shortcut pack collections
└── utils/                   # Storage, URL matching, conflict detection, JS snippets

site/                        # shortkeys.app (Astro SSG, deployed to Netlify)
tests/                       # 722 tests across 25 files
marketing/                   # Store listing copy, screenshot plans, promo assets

Tech stack

  • WXT - Vite-based browser extension framework
  • Vue 3 - Composition API with <script setup>
  • TypeScript throughout
  • Vitest - 722 tests across 25 files
  • Mousetrap - keyboard shortcut detection
  • CodeMirror 6 - JavaScript editor with syntax highlighting
  • Astro - community website (shortkeys.app)

Contributing

Pull requests are welcome. Please ensure all tests pass (npm test) before submitting. For bugs and feature requests, open a GitHub issue.

Support

Shortkeys is free and open source. If you find it useful, consider supporting development:

Credits and license

Icon by Freepik from Flaticon.

Licensed under the MIT License.

Extension points exported contracts — how you extend this code

PackConflictInfo (Interface)
Conflict metadata for a single pack shortcut
src/composables/usePacks.ts
MockKeyEvent (Interface)
* Tests for the ShortcutRecorder key capture logic. * Uses e.code (physical key) to avoid unicode issues with Alt on Ma
tests/shortcut-recorder.test.ts
TabInfo (Interface)
(no doc)
src/actions/last-used-tab.ts
ShortcutUsageEntry (Interface)
(no doc)
src/utils/usage-tracking.ts
ShortcutPack (Interface)
(no doc)
src/packs/index.ts
CommunityPackJson (Interface)
(no doc)
scripts/build-catalog.ts
CommunityPackJson (Interface)
(no doc)
tests/community-packs.test.ts
CommunityPackConflictInfo (Interface)
Conflict metadata for a single community pack shortcut
src/composables/useCommunityPacks.ts

Core symbols most depended-on inside this repo

handleAction
called by 119
src/actions/action-handlers.ts
executeScript
called by 41
src/utils/execute-script.ts
normalizeKey
called by 38
src/utils/shortcut-conflicts.ts
showPageToast
called by 36
src/utils/execute-script.ts
isAllowedSite
called by 35
src/utils/url-matching.ts
isGroupAllowed
called by 33
src/utils/url-matching.ts
useShortcuts
called by 31
src/composables/useShortcuts.ts
useUndoRedo
called by 31
src/composables/useUndoRedo.ts

Shape

Function 206
Interface 18
Class 6
Method 6

Languages

TypeScript100%

Modules by API surface

src/utils/link-hints.ts15 symbols
src/composables/useGroups.ts15 symbols
src/entrypoints/content.ts11 symbols
src/utils/usage-tracking.ts10 symbols
src/utils/shortcut-conflicts.ts10 symbols
src/composables/useShortcuts.ts10 symbols
src/composables/useCommunityPacks.ts10 symbols
src/actions/action-handlers.ts10 symbols
src/utils/url-matching.ts7 symbols
src/composables/useMacros.ts7 symbols
src/composables/useDragDrop.ts7 symbols
src/utils/storage.ts6 symbols

For agents

$ claude mcp add shortkeys \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact