Docs
CodeRabbit
Cloudflare
AG Grid
SerpAPI
Netlify
OpenRouter
Neon
WorkOS
Clerk
Electric
PowerSync
Sentry
Railway
Prisma
Strapi
Unkey
CodeRabbit
Cloudflare
AG Grid
SerpAPI
Netlify
OpenRouter
Neon
WorkOS
Clerk
Electric
PowerSync
Sentry
Railway
Prisma
Strapi
Unkey
Hotkeys API Reference
App Hotkeys API Reference
Key hold & held keys API Reference
Hotkey Recorder API Reference
Normalization & format API Reference
App Hotkeys API Reference

getAppHotkeys

ts
function getAppHotkeys(): SvelteAppHotkeys;
function getAppHotkeys(): SvelteAppHotkeys;

Defined in: packages/svelte-hotkeys/src/getAppHotkeys.svelte.ts:41

Returns reactive access to the effective app hotkeys from HotkeysProvider, typed by Register.

Returns

SvelteAppHotkeys

Example

svelte
<script lang="ts">
  const appHotkeys = getAppHotkeys()
  createHotkey(() => appHotkeys.current['doc.save'], () => save())
</script>
<script lang="ts">
  const appHotkeys = getAppHotkeys()
  createHotkey(() => appHotkeys.current['doc.save'], () => save())
</script>