i18n-boundary

i18n-boundary is a cursor rule for Cursor from YuDefine/nuxt-supabase-starter. It costs 0 tokens per session (754 once invoked), scanned A, original, MIT.

A rule for deciding which parts of an application use translations and which deliberately stay in one language. It also defines where server error codes become user-facing text.

In plain words
What is it for?
Use it when planning multilingual screens, emails, notifications, server errors, and translation-related lint checks.
Why use it?
It prevents inconsistent translation behavior and avoids using unstable server messages as translation keys or client logic.

Cursor rule for Cursor

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

Good fit Use it when planning multilingual screens, emails, notifications, server errors, and translation-related lint checks.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/yudefine/nuxt-supabase-starter/i18n-boundary
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.

Clone the repo
git clone --depth 1 https://github.com/YuDefine/nuxt-supabase-starter

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 i18n-boundary

README.md
[![agentmods](https://agentmods.dev/badge/rules/yudefine/nuxt-supabase-starter/i18n-boundary.svg)](https://agentmods.dev/rules/yudefine/nuxt-supabase-starter/i18n-boundary)
Your own site
<a href="https://agentmods.dev/rules/yudefine/nuxt-supabase-starter/i18n-boundary"><img src="https://agentmods.dev/badge/rules/yudefine/nuxt-supabase-starter/i18n-boundary.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 754 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
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.00754
Opus 5 $0.00000 $0.00377
Sonnet 5 $0.00000 $0.00151
Haiku 4.5 $0.00000 $0.00075

Measured today against content hash 3f80b982d217, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-08, from the pricing page.

Security

Grade A, and why

i18n-boundary 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 today.

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.

template/.cursor/rules/i18n-boundary.mdc · 40 lines

What it actually says

i18n Scope Boundary

本規約適用於每一個有 UI 的 consumer,不論目前採多語系、單一語言,或只有部分 surface 使用 i18n。

Boundary 是架構決策

當 i18n 覆蓋範圍是刻意決策時,consumer MUST 同時留下兩層記錄:

  1. docs/decisions/YYYY-MM-DD-i18n-scope-boundary.md ADR:記錄決策背景、取捨、翻譯責任與重評條件。
  2. DESIGN.md## i18n Scope Boundary 專節:讓日常 UI 實作可直接查到目前邊界。

兩層記錄都 MUST 明列:

  • 哪些 product surface/route/package 使用 i18n。
  • 哪些 surface 刻意硬編碼單一語言,以及該語言與理由。
  • server error、client UI、email/通知等 surface 各自由哪一層負責翻譯。
  • 哪些可觀察條件會觸發重評,例如新增 locale、公開新的 customer-facing surface 或進入新市場。

關閉 no-untranslatedno-raw-text 或同類 lint 規則時,MUST 在同一份 i18n scope ADR 記錄 rule 名稱、受影響路徑、關閉理由與恢復/重評條件。Lint 設定本身的註解不能取代 ADR。

Error Localization Boundary

  • 每一個 server error 都 MUST 回傳 stable code 或等價的 error catalog identity;可讀 message 不得成為 client 分支或翻譯 key。
  • 翻譯責任 MUST 留在 ADR/DESIGN.md 宣告的 client layer,由該層把 stable code 轉成使用者可見文字。
  • 既有硬編碼字串依宣告的 surface boundary 漸進收斂。NEVER 只靠 grep 找字串後一次性搬進 locale 檔;這會漏掉動態文案、破壞刻意硬編碼的 surface,且無法驗證翻譯責任。
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. today Changed · +1 lines 3f80b982d217
  2. 4d ago First seen · 39 lines · 0 tokens per session scan A 998f0bf27c1d

Subscribe to this mod's changes

i18n-boundary is a cursor rule published in the GitHub repository YuDefine/nuxt-supabase-starter (45 stars, last pushed today), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 754 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.