mirror of
https://github.com/Jeuners/ECC.git
synced 2026-09-09 15:02:30 +02:00
fix(rules): add paths frontmatter to web rule pack (#2425)
Every other language pack (typescript, react, python, golang, vue, ...) scopes its rules with a paths: YAML frontmatter block, so Claude Code only loads them when matching files are in context. The 7 files in rules/web/ ship without frontmatter, and per the official rules-loading docs (https://code.claude.com/docs/en/memory) rules without a paths field load unconditionally into every session - ~15.5KB of always-on context even in projects with no frontend code. Add the same frontmatter convention used by the react pack, scoped to web-facing file types (css/scss/sass/less/html/tsx/jsx/vue/svelte).
This commit is contained in:
parent
fb37c23c84
commit
e05a201258
7 changed files with 84 additions and 0 deletions
|
|
@ -1,3 +1,15 @@
|
||||||
|
---
|
||||||
|
paths:
|
||||||
|
- "**/*.css"
|
||||||
|
- "**/*.scss"
|
||||||
|
- "**/*.sass"
|
||||||
|
- "**/*.less"
|
||||||
|
- "**/*.html"
|
||||||
|
- "**/*.tsx"
|
||||||
|
- "**/*.jsx"
|
||||||
|
- "**/*.vue"
|
||||||
|
- "**/*.svelte"
|
||||||
|
---
|
||||||
> This file extends [common/coding-style.md](../common/coding-style.md) with web-specific frontend content.
|
> This file extends [common/coding-style.md](../common/coding-style.md) with web-specific frontend content.
|
||||||
|
|
||||||
# Web Coding Style
|
# Web Coding Style
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,15 @@
|
||||||
|
---
|
||||||
|
paths:
|
||||||
|
- "**/*.css"
|
||||||
|
- "**/*.scss"
|
||||||
|
- "**/*.sass"
|
||||||
|
- "**/*.less"
|
||||||
|
- "**/*.html"
|
||||||
|
- "**/*.tsx"
|
||||||
|
- "**/*.jsx"
|
||||||
|
- "**/*.vue"
|
||||||
|
- "**/*.svelte"
|
||||||
|
---
|
||||||
> This file extends [common/patterns.md](../common/patterns.md) with web-specific design-quality guidance.
|
> This file extends [common/patterns.md](../common/patterns.md) with web-specific design-quality guidance.
|
||||||
|
|
||||||
# Web Design Quality Standards
|
# Web Design Quality Standards
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,15 @@
|
||||||
|
---
|
||||||
|
paths:
|
||||||
|
- "**/*.css"
|
||||||
|
- "**/*.scss"
|
||||||
|
- "**/*.sass"
|
||||||
|
- "**/*.less"
|
||||||
|
- "**/*.html"
|
||||||
|
- "**/*.tsx"
|
||||||
|
- "**/*.jsx"
|
||||||
|
- "**/*.vue"
|
||||||
|
- "**/*.svelte"
|
||||||
|
---
|
||||||
> This file extends [common/hooks.md](../common/hooks.md) with web-specific hook recommendations.
|
> This file extends [common/hooks.md](../common/hooks.md) with web-specific hook recommendations.
|
||||||
|
|
||||||
# Web Hooks
|
# Web Hooks
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,15 @@
|
||||||
|
---
|
||||||
|
paths:
|
||||||
|
- "**/*.css"
|
||||||
|
- "**/*.scss"
|
||||||
|
- "**/*.sass"
|
||||||
|
- "**/*.less"
|
||||||
|
- "**/*.html"
|
||||||
|
- "**/*.tsx"
|
||||||
|
- "**/*.jsx"
|
||||||
|
- "**/*.vue"
|
||||||
|
- "**/*.svelte"
|
||||||
|
---
|
||||||
> This file extends [common/patterns.md](../common/patterns.md) with web-specific patterns.
|
> This file extends [common/patterns.md](../common/patterns.md) with web-specific patterns.
|
||||||
|
|
||||||
# Web Patterns
|
# Web Patterns
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,15 @@
|
||||||
|
---
|
||||||
|
paths:
|
||||||
|
- "**/*.css"
|
||||||
|
- "**/*.scss"
|
||||||
|
- "**/*.sass"
|
||||||
|
- "**/*.less"
|
||||||
|
- "**/*.html"
|
||||||
|
- "**/*.tsx"
|
||||||
|
- "**/*.jsx"
|
||||||
|
- "**/*.vue"
|
||||||
|
- "**/*.svelte"
|
||||||
|
---
|
||||||
> This file extends [common/performance.md](../common/performance.md) with web-specific performance content.
|
> This file extends [common/performance.md](../common/performance.md) with web-specific performance content.
|
||||||
|
|
||||||
# Web Performance Rules
|
# Web Performance Rules
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,15 @@
|
||||||
|
---
|
||||||
|
paths:
|
||||||
|
- "**/*.css"
|
||||||
|
- "**/*.scss"
|
||||||
|
- "**/*.sass"
|
||||||
|
- "**/*.less"
|
||||||
|
- "**/*.html"
|
||||||
|
- "**/*.tsx"
|
||||||
|
- "**/*.jsx"
|
||||||
|
- "**/*.vue"
|
||||||
|
- "**/*.svelte"
|
||||||
|
---
|
||||||
> This file extends [common/security.md](../common/security.md) with web-specific security content.
|
> This file extends [common/security.md](../common/security.md) with web-specific security content.
|
||||||
|
|
||||||
# Web Security Rules
|
# Web Security Rules
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,15 @@
|
||||||
|
---
|
||||||
|
paths:
|
||||||
|
- "**/*.css"
|
||||||
|
- "**/*.scss"
|
||||||
|
- "**/*.sass"
|
||||||
|
- "**/*.less"
|
||||||
|
- "**/*.html"
|
||||||
|
- "**/*.tsx"
|
||||||
|
- "**/*.jsx"
|
||||||
|
- "**/*.vue"
|
||||||
|
- "**/*.svelte"
|
||||||
|
---
|
||||||
> This file extends [common/testing.md](../common/testing.md) with web-specific testing content.
|
> This file extends [common/testing.md](../common/testing.md) with web-specific testing content.
|
||||||
|
|
||||||
# Web Testing Rules
|
# Web Testing Rules
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue