From b1b0fd82b66c969f608470b96b9c0cc15420b1cd Mon Sep 17 00:00:00 2001 From: aos <25783780+aos@users.noreply.github.com> Date: Mon, 26 Jan 2026 03:42:49 -0500 Subject: [PATCH] docs: add blurb about not hardcoding keybindings (#955) --- AGENTS.md | 1 + 1 file changed, 1 insertion(+) diff --git a/AGENTS.md b/AGENTS.md index ce9651c3..1a8cf10a 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -17,6 +17,7 @@ read README.md, then ask which module(s) to work on. Based on the answer, read t - **NEVER use inline imports** - no `await import("./foo.js")`, no `import("pkg").Type` in type positions, no dynamic imports for types. Always use standard top-level imports. - NEVER remove or downgrade code to fix type errors from outdated dependencies; upgrade the dependency instead - Always ask before removing functionality or code that appears to be intentional +- Never hardcode key checks with, eg. `matchesKey(keyData, "ctrl+x")`. All keybindings must be configurable. Add default to matching object (`DEFAULT_EDITOR_KEYBINDINGS` or `DEFAULT_APP_KEYBINDINGS`) ## Commands - After code changes (not documentation changes): `npm run check` (get full output, no tail). Fix all errors, warnings, and infos before committing.