typescript-coding-convention

typescript-coding-convention is a cursor rule for Cursor from yu-iskw/skill-inspector. It costs 3,499 tokens per session, scanned A, a copy of typescript-coding-convention, Apache-2.0.

A set of rules for writing TypeScript code, including naming, syntax, and identifier conventions. TypeScript is JavaScript with features that help describe and check data types before the code runs.

In plain words
What is it for?
Use it as a reference when naming classes, functions, variables, types, constants, and test methods in TypeScript projects.
Why use it?
It gives a team consistent code patterns, making files easier to read, review, and maintain.

Cursor rule for Cursor

Written for Cursor: installed under .cursor/.

Good fit Use it as a reference when naming classes, functions, variables, types, constants, and test methods in TypeScript projects.

Compare 6 cursor rules from other repositories ↓
Install with agentmods
npx agentmods add rules/yu-iskw/skill-inspector/typescript-coding-convention
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/yu-iskw/skill-inspector

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 typescript-coding-convention

README.md
[![agentmods](https://agentmods.dev/badge/rules/yu-iskw/skill-inspector/typescript-coding-convention/github.svg)](https://agentmods.dev/rules/yu-iskw/skill-inspector/typescript-coding-convention)
Your own site
<a href="https://agentmods.dev/rules/yu-iskw/skill-inspector/typescript-coding-convention"><img src="https://agentmods.dev/badge/rules/yu-iskw/skill-inspector/typescript-coding-convention/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.

agentmods 80×15 button for typescript-coding-convention

Your own site · 80×15
<a href="https://agentmods.dev/rules/yu-iskw/skill-inspector/typescript-coding-convention"><img src="https://agentmods.dev/badge/rules/yu-iskw/skill-inspector/typescript-coding-convention.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 3,499 This file is loaded in full into every session.
When invoked 3,499 The same file — it is already loaded in full.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin 98% copy Near-identical to another mod 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.03499 $0.03499
Opus 5.5 $0.01400 $0.01400
Sonnet 5.5 $0.00700 $0.00700
Haiku 4.5 $0.00350 $0.00350

Measured 1mo ago against content hash 7a3ad22d8a9c, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

typescript-coding-convention 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 1mo 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.

Origin

This is a copy

98% identical to typescript-coding-convention — 6 lines differ, which has more behind it and is treated as the original. This page carries a canonical link to it rather than competing with it.

.cursor/rules/typescript-coding-convention.mdc · 281 lines

How it starts

The opening of the file, as written. The whole thing — 281 lines — stays where its author put it; the contents beside it link to each section on GitHub.

TypeScript Style Guide

This guide outlines the default-standard coding conventions for TypeScript, based on the Google TypeScript Style Guide, supplemented with best practices from other widely-used TypeScript style guides.

1. Syntax

1.1. Identifiers

Identifiers must use only ASCII letters, digits, underscores (for constants and structured test method names), and the '$' sign.

Style Category
UpperCamelCase class / interface / type / enum / decorator / type / parameters
lowerCamelCase variable / parameter / function / method / property / module alias
CONSTANT_CASE global constant values, including enum values
  • Abbreviations: Treat abbreviations like acronyms as whole words (e.g., loadHttpUrl, not loadHTTPURL).
  • Dollar sign: Avoid using $ in identifiers, except when aligning with third-party framework conventions (e.g., jquery).
  • Type parameters: May use a single upper case character (T) or UpperCamelCase.
  • Test names: Test method names may be structured with _ separators (e.g., testX_whenY_doesZ()).
  • _ prefix/suffix: Do not use _ as a prefix or suffix, or as an identifier by itself.

1.2. Aliases

When aliasing an existing symbol, use the format of the existing identifier. For variables, use const, and for class fields, use readonly.

1.3. Naming Style

Names should not be decorated with information already included in the type.

  • Do not use trailing or leading underscores for private properties or methods.
  • Do not use the opt_ prefix for optional parameters.
  • Do not prefix interfaces with I (e.g., IUser should be User).
  • Prefix booleans with is or has for clarity (e.g., isLoggedIn, hasPermission).

1.4. File Encoding

For non-ASCII characters, use the actual Unicode character (e.g., ∞). For non-printable characters, the equivalent hex or Unicode escapes (e.g., \u221e) can be used along with an explanatory comment.

Read the full file on GitHub · 281 lines

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. 1mo ago First seen · 281 lines · 3,499 tokens per session scan A 7a3ad22d8a9c

Subscribe to this mod's changes

typescript-coding-convention is a cursor rule published in the GitHub repository yu-iskw/skill-inspector (2 stars, last pushed 20d ago), licensed Apache-2.0. It adds 3,499 tokens to every session, about $0.0140 per session on Opus 5.5. A static security scan graded it A with 0 findings. It is 98% identical to typescript-coding-convention, differing in 6 lines, and is treated as a copy.