Skip to content

CONTRIBUTING.md should document the dual keyboard shortcut system (useKeyboardShortcut vs direct addEventListener) #941

Open

Description

@nonsobethel0-dev

Summary

The codebase has two keyboard shortcut patterns:

  1. useKeyboardShortcut hook (used by NavBar for Escape and ?)
  2. Direct window.addEventListener in SearchBar (Ctrl+K)

This dual system isn't documented anywhere. A contributor adding a new shortcut wouldn't know which to use.

Severity

Low

Suggested Fix

Add a section to CONTRIBUTING.md: "Adding keyboard shortcuts" that recommends useKeyboardShortcut and explains when direct listeners are acceptable.

Activity

  1. added
    documentation
    on Nov 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    documentation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions