coding-standards

Universal coding standards for TypeScript, JavaScript, React, and Node.js. Principles: readability first, KISS, DRY, YAGNI. Covers naming, type safety, error handling, async patterns, React hooks, API design, file organization, performance, testing, code smells. Trigger phrases: coding standards, best practices, code review, quality standards, naming conventions.

Safety Notice

This listing is from the official public ClawHub registry. Review SKILL.md and referenced scripts before running.

Copy this and send it to your AI assistant to learn

Install skill "coding-standards" with this command: npx skills add djc00p/coding-standards

Coding Standards & Best Practices

Universal standards for maintainable, scalable TypeScript/JavaScript code.

Quick Start

  1. Readability First — Clear names, self-documenting code
  2. Type Safety — Avoid any, use explicit interfaces
  3. Error Handling — Try-catch with specific error types
  4. Immutability — Use spread operator, never direct mutation
  5. Test Structure — AAA pattern (Arrange, Act, Assert)

Core Principles

KISS — Simplest solution that works. No premature optimization.

DRY — Extract common logic into reusable functions and components.

YAGNI — Don't build before it's needed. Start simple, refactor when needed.

Readability — Code is read 10x more than written. Clarity over cleverness.

Naming Standards

Variables

// Good: Descriptive, type-hinted by name
const marketSearchQuery = 'election'
const isUserAuthenticated = true
const totalRevenue = 1000

// Bad: Single-letter, unclear
const q = 'election'
const flag = true
const x = 1000

Functions

// Good: Verb-noun pattern
async function fetchMarketData(id: string) { }
function calculateSimilarity(a: number[], b: number[]) { }
function isValidEmail(email: string): boolean { }

// Bad: Unclear or noun-only
async function market(id: string) { }
function similarity(a, b) { }
function email(e) { }

References

  • references/typescript.md — type safety, immutability, async patterns
  • references/react.md — component structure, hooks, state management
  • references/api-design.md — REST conventions, validation, error responses
  • references/file-org.md — project structure, file naming
  • references/testing.md — test patterns, AAA structure, test naming
  • references/code-smells.md — anti-patterns, long functions, deep nesting, magic numbers

Adapted from everything-claude-code by @affaan-m (MIT)

Source Transparency

This detail page is rendered from real SKILL.md content. Trust labels are metadata-based hints, not a safety guarantee.

Related Skills

Related by shared tags or category signals.

Coding

Phone agent

Use AI AutoGLM Phone Agent for automated mobile device control. Suitable for tasks requiring mobile phone automation, such as APP automated testing, data col...

Registry SourceRecently Updated
Coding

Hk LeETF

Analyzes Hong Kong leveraged ETFs by evaluating holdings, price deviation, liquidity risks, and provides rebalancing timing, arbitrage opportunities, and ris...

Registry SourceRecently Updated
Coding

client-onboard

Generate a complete client onboarding package from a project description. Creates project brief, tech stack, milestones, folder structure, CLAUDE.md, and a r...

Registry SourceRecently Updated
Coding

workflow-migrate

Migrate N8N/Zapier/Make workflows to production-grade Python or Node.js scripts. Given a workflow description or paste, rewrites automation logic with retry,...

Registry SourceRecently Updated