ia: add directive to claude code regarding the frontend checks

This commit is contained in:
Edouard Vanbelle
2026-05-19 10:06:43 +02:00
parent 09b8550067
commit 73114acf39
+12
View File
@@ -130,6 +130,7 @@ Never duplicate logic across handlers or services. If the same behaviour is need
- Naming: `camelCase` for variables/functions, `PascalCase` for classes
- No `var` — use `const`/`let` only
- **JSDoc required** on all public functions — `jsconfig.json` enables `checkJs` globally (equivalent to `@ts-check` on every file)
- Always us static/js/core/types.js to mapp OxCcloud API structure
- Type parameters, return types, and complex types via `@typedef`:
```js
@@ -162,6 +163,17 @@ Never duplicate logic across JS modules. If the same behaviour is needed in more
- One CSS file per logical component in `/static/css/`
- [data-theme="dark"] is permitted only in /static/css/themes/dark.css
## Frontend Pre-commit checks
Always run these before committing, in this order:
```bash
biome check --fix # Auto-format
biome lint --fix # Lint (must pass)
stylelint static/css/ # Css rules
tsc -p jsconfig.json --noEmit # Ensure JS is always typed
```
# What Claude must NOT do
- Edit `Cargo.lock` directly
- Use npm dependencies not listed in this file