# Svelte Check - Pre-commit Enforcement
Last updated: 2024-12-15
## Overview
All web apps in this monorepo are protected by **pre-commit hooks** that run `svelte-check` with `--threshold warning`. This ensures no a11y issues, TypeScript errors, or Svelte 5 problems can be committed.
## Current Status
All main web apps pass svelte-check with **0 errors and 0 warnings**:
| Package | Status |
|---------|--------|
| @manacore/web | Clean |
| @clock/web | Clean |
| @chat/web | Clean |
| @manadeck/web | Clean |
| @calendar/web | Clean |
| @zitare/web | Clean |
| @contacts/web | Clean |
| @picture/web | Clean |
| @todo/web | Clean |
## How It Works
### Pre-commit Hook
When you commit `.svelte` files, the hook automatically:
1. Detects which web apps have changes
2. Runs `svelte-check --threshold warning` on affected apps
3. **Blocks the commit** if any warnings or errors are found
```bash
# What happens on commit:
🔍 Running svelte-check on affected web apps...
━━━ Checking apps/todo/apps/web ━━━
✅ svelte-check passed for apps/todo/apps/web
✅ All svelte-checks passed!
```
### If Check Fails
```bash
━━━ Checking apps/todo/apps/web ━━━
/path/to/file.svelte:42:3
Warn: Elements with onclick must have onkeydown handler
❌ svelte-check failed for apps/todo/apps/web
❌ svelte-check failed! Fix the issues above before committing.
```
You must fix the warnings before you can commit.
---
## Common Warnings & How to Fix Them
### 1. Click Events Need Keyboard Events
**Warning:** `a11y_click_events_have_key_events`
```svelte