From f14394ab6fd1862331e83bbbf0c323e7c610a35e Mon Sep 17 00:00:00 2001 From: PD <9029198+pdx91@users.noreply.github.com> Date: Wed, 16 Jul 2025 20:46:31 -0700 Subject: [PATCH] Add an example for custom key mappings --- docs/reference/actions.md | 15 ++++++++++++++- 1 file changed, 14 insertions(+), 1 deletion(-) diff --git a/docs/reference/actions.md b/docs/reference/actions.md index 6aa43db3..b76e4d63 100644 --- a/docs/reference/actions.md +++ b/docs/reference/actions.md @@ -106,12 +106,25 @@ import { Application, defaultSchema } from "@hotwired/stimulus" const customSchema = { ...defaultSchema, - keyMappings: { ...defaultSchema.keyMappings, at: "@" }, + keyMappings: { + ...defaultSchema.keyMappings, + at: "@", + slash: "/", + question: "?" + }, } const app = Application.start(document.documentElement, customSchema) ``` +Then use them in your action descriptors: + +```html +