code-style

code-style is a cursor rule for Cursor from louisbrulenaudet/monorepo-template. It costs 0 tokens per session (366 once invoked), scanned A, original, Apache-2.0.

A repository-specific guide for formatting, linting, and structuring TypeScript code. It explains how route and tool handlers should delegate work and how to fix, rather than hide, lint errors.

In plain words
What is it for?
Use it when writing handlers, changing lint or format rules, or deciding where validation and input/output code belongs.
Why use it?
It prevents personal formatting choices, misplaced business logic, and ignored warnings from causing inconsistent code or failed CI checks.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/. Also seen: mentions AGENTS.md.

Install

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.

agentmods
npx agentmods add rules/louisbrulenaudet/monorepo-template/code-style
Clone the repo
git clone --depth 1 https://github.com/louisbrulenaudet/monorepo-template

Made for: Cursor.

Wrote 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.

agentmods badge for code-style

README.md
[![agentmods](https://agentmods.dev/badge/rules/louisbrulenaudet/monorepo-template/code-style.svg)](https://agentmods.dev/rules/louisbrulenaudet/monorepo-template/code-style)
Your own site
<a href="https://agentmods.dev/rules/louisbrulenaudet/monorepo-template/code-style"><img src="https://agentmods.dev/badge/rules/louisbrulenaudet/monorepo-template/code-style.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Nothing until a file matches its globs; then the whole rule loads.
When invoked 366 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00000 $0.00366
Opus 5 $0.00000 $0.00183
Sonnet 5 $0.00000 $0.00073
Haiku 4.5 $0.00000 $0.00037

Measured 2d ago against content hash ad3150189557, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

code-style 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 2d 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.

.cursor/rules/quality/code-style.mdc · 17 lines

What it actually says

Code Style

OXC is the source of truth: .oxlintrc.json (lint) and .oxfmtrc.json (format). Do not restyle to match personal habits - match the surrounding file and let oxfmt decide layout. These rules run with denyWarnings: true / maxWarnings: 0, so any warning fails CI. Do not silence a rule, add a blanket ignore, or cast through any / as unknown to clear an error - fix the cause (see guardrails.mdc).

Discipline

  • Keep route/tool handlers thin: validate at the boundary, delegate I/O to a client or service module, then map the response. Business logic does not belong inline in the handler.
  • Prefer native type inference (see type-inference.mdc) over hand-written shapes.
  • Lint and format run as a whole-repo OXC pass from the root - never cd into a package and run oxlint . (breaks context-aware Tailwind rules). See Scoping in root AGENTS.md.
  • Inline suppressions use the oxlint-* form only (// oxlint-disable-next-line <rule> with a reason). .oxlintrc.json sets respectEslintDisableDirectives: false, so eslint-disable* comments are ignored by the linter and, via reportUnusedDisableDirectives: "error", any stray one fails CI.
Changes

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.

  1. 2d ago First seen · 17 lines · 0 tokens per session scan A ad3150189557

Subscribe to this mod's changes

code-style is a cursor rule published in the GitHub repository louisbrulenaudet/monorepo-template (19 stars, last pushed 4d ago), licensed Apache-2.0. It costs nothing until one of its globs matches a file; then it loads 366 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-09-03.