CtrlK
BlogDocsLog inGet started
Tessl Logo
SkillPublic

app-coding-standards

Provides coding standards for the Expensify App's React Native code, including performance patterns, consistency rules, and clean React architecture. Use when writing, modifying, or reviewing App code.

Quality

83%

Does it follow best practices?

Run evals on this skill

Adds up to 20 points to the overall score

View guide
SecuritybySnyk

Passed

No findings from the security scan

SKILL.md
Quality
Evals
Security

Expensify App Coding Standards

Coding standards for the Expensify App. Each standard is a standalone file in rules/ with reasoning, examples, and applicability conditions.

How to Use

This index lists rule titles only. Before writing or editing code, read the full rule file for every category that applies to the files you touch: each file holds the rule's conditions, exceptions, and the fix it expects.

Before committing, stage everything with git add -A. Then start a general-purpose subagent that follows .claude/agents/code-inline-reviewer.md and reviews git diff --cached $(git merge-base origin/main HEAD). CI runs the same check.

Categories

CategoryPrefixFocus
PerformancePERF-*Render optimization, memo patterns, useEffect hygiene, data selection
ConsistencyCONSISTENCY-*Platform checks, magic values, unused props, ESLint discipline, localization, file naming, JSDoc
Clean React PatternsCLEAN-REACT-PATTERNS-*Composition, component ownership, state structure, prop typing, function components
UIUI-*Loading indicators, scrollable pages, styling conventions

Quick Reference

Performance

  • PERF-1 — No spread in renderItem
  • PERF-2 — Return early before expensive work
  • PERF-3 — Shared data in list rows comes from OnyxListItemProvider
  • PERF-5 — Shallow over deep comparisons
  • PERF-6 — Derive state from props
  • PERF-7 — Reset via key prop
  • PERF-8 — Handle events in handlers
  • PERF-9 — No useEffect chains
  • PERF-10 — No useEffect parent communication
  • PERF-11 — Optimize data selection
  • PERF-12 — Prevent memory leaks
  • PERF-13 — Hoist iterator-independent calls
  • PERF-14 — Use useSyncExternalStore
  • PERF-15 — Clean up async Effects
  • PERF-16 — Guard double initialization
  • PERF-17 — Pass raw source, index on demand (no pre-built digest)
  • PERF-18 — Use usePreMountDestination for RHP pre-mounting
  • PERF-19 — Collection selectors return only what the consumer uses
  • PERF-20 — Defer heavy work to happen after visual transitions
  • PERF-21 — List rows read their own Onyx data
  • PERF-22 — List rows subscribe to single collection members

Consistency

Clean React Patterns

UI

  • UI-1 — Use the correct loading indicator based on navigation context
  • UI-2 — New pages must be scrollable
  • UI-3 — Do not use inline style objects
  • UI-4 — Type and responsive insets come from tokens
  • UI-5 — Reuse an existing style or StyleUtils helper instead of adding a new one

Onyx

  • ONYX-1 — Keep Onyx reads off the render path and out of a written tick
Repository

Expensify/App

Path

.claude/skills/app-coding-standards/SKILL.md

Last updated
First committed

Is this your skill?

If you maintain this skill, you can claim it as your own. Once claimed, you can manage eval scenarios, bundle related skills, attach documentation or rules, and ensure cross-agent compatibility.