Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
git clone --depth 1 https://github.com/vanessamarely/ai-playbook-repositoWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/rules/vanessamarely/ai-playbook-reposito/frontend-policy)<a href="https://agentmods.dev/rules/vanessamarely/ai-playbook-reposito/frontend-policy"><img src="https://agentmods.dev/badge/rules/vanessamarely/ai-playbook-reposito/frontend-policy/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/rules/vanessamarely/ai-playbook-reposito/frontend-policy"><img src="https://agentmods.dev/badge/rules/vanessamarely/ai-playbook-reposito/frontend-policy.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.00542 |
| Opus 5 | $0.00000 | $0.00271 |
| Sonnet 5 | $0.00000 | $0.00108 |
| Haiku 4.5 | $0.00000 | $0.00054 |
Grade A, and why
frontend-policy scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 75 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Frontend Policy
Technology Stack
Primary focus: React + TypeScript applications.
Core Principles
- Component-driven architecture with clear boundaries.
- Type safety enforced at compile time.
- Accessibility as a first-class requirement.
- Performance considerations in rendering and bundling.
React + TypeScript Standards
Component Structure
- Use functional components with hooks.
- Define explicit TypeScript interfaces for props.
- Co-locate types with components when project-specific; extract shared types to dedicated type definition files.
State Management
- Use
useStatefor local component state. - Use
useReducerfor complex state logic. - Lift state only when necessary.
- Consider context for cross-cutting concerns.
Effect Management
- Use
useEffectwith explicit dependency arrays. - Clean up side effects (subscriptions, timers, listeners).
- Avoid effects for derived state; use
useMemoor direct computation.
Event Handlers
- Prefix handler functions with
handle(e.g.,handleClick). - Use inline arrow functions sparingly (consider performance implications).
- Type event parameters explicitly (e.g.,
React.MouseEvent<HTMLButtonElement>).
Accessibility Policy
All frontend code must meet WCAG 2.2 Level AA standards.
- Semantic HTML as foundation.
- Keyboard navigation support (Tab, Enter, Escape, Arrow keys).
- Valid ARIA usage (roles, states, properties).
- Focus management for dynamic content and modals.
- Perceivable contrast ratios (4.5:1 normal text, 3:1 large text).
- Reduced motion support via
prefers-reduced-motion.
Tooling Assumptions
eslint-plugin-jsx-a11yconfigured and enforced.@axe-core/reactor equivalent for runtime checks in development.- Manual keyboard testing required for interactive components.
For the full WCAG 2.2 checklist, anti-patterns, and ARIA patterns, see the a11y-automation and react-components rules (both auto-apply to .tsx/.jsx files).
Error Boundaries
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 10d ago First seen · 75 lines · 0 tokens per session scan A 158ddc59f694
frontend-policy is a cursor rule published in the GitHub repository vanessamarely/ai-playbook-reposito (2 stars, last pushed 1mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 542 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other cursor rules, from other repositories
windsurfrules
Create detailed components with these requirements.
state-management
Use the following stack. Do not introduce or recommend Redux or React Context for shared/global state.
mobx
Definitive guidelines for structuring MobX applications with React, focusing on predictable state management, optimal rendering, and modern best practices.
tanstack-start-guide
TanStack Start best practices emphasizing client-first architecture, type safety, and modern React patterns.
new-component
Workflow for creating new React components.
middleware-auth
Next.js middleware auth — prevents auth logic being placed in middleware instead of route handlers.