agentleFS
siberiacancodesiberiacancode/agent-skills/skills/juniors-best-practice/AGENTS.md

agent-skills / juniors-best-practice

AGENTS.md23 starsChanged 2 months agoMITView on GitHub

Version 1.0.0 siberiacancode February 2026 Note: This document is optimized for agents and LLMs working on junior-friendly React and TypeScript codebases. It emphasizes clarity, consistency, and practical guidance. Juniors-focused best practices for React and TypeScript projects, organized by practical scopes (JS, React, styling, devtools, and more). Each guide includes concise guidance and examples that help early-career developers write clear, consistent, and maintainable code. Use early returns to reduce nesting and keep control flow easy to read. Prefer positive names to…

The file

Show its rules and text

We split this AGENTS.md into the rules it gives an agent

20 rules. About 0 are common, 11 are distinctive, and 9 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈11

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 9

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Use early returns to reduce nesting and keep control flow easy to read.

    line 67
  2. Very specific:

    Prefer positive names to avoid confusing !isNotX conditions.

    line 71
  3. Distinctive:

    Avoid destructuring when it hurts clarity or creates renaming noise.

    line 75
  4. Very specific:

    Default to const and use let only for real mutation.

    line 79
  5. Very specific:

    Prefer ?? when falsy values like 0 or false are valid.

    line 83
  6. Very specific:

    Keep arrow functions concise by removing redundant return.

    line 87
  7. Very specific:

    Use UPPER_CASE only for stable, application-level constants.

    line 91
  8. Distinctive:

    Use aliases that avoid collisions with external packages.

    line 97
  9. Distinctive:

    Prefer flat translation keys to avoid deep nesting, reduce duplication, and simplify lookup in locale files.

    line 101
  10. Distinctive:

    Use string literals directly when no expression is needed.

    line 107
  11. Very specific:

    Use children for flexible composition and typing clarity.

    line 111
  12. Distinctive:

    Keep prop types nearby and readable.

    line 119
  13. Very specific:

    Use a helper like clsx for conditional class names.

    line 125
  14. Very specific:

    Prefer CSS selectors for hover/disabled/focus styling.

    line 129
  15. Distinctive:

    Use formatters and linters to keep code consistent.

    line 135
  16. Distinctive:

    Keep imports ordered and grouped for readability.

    line 139
  17. Distinctive:

    Use one package manager and a single lock file.

    line 143
  18. Distinctive:

    Use SVGs as components for scalable, themeable icons.

    line 149
  19. Distinctive:

    Use a consistent commit message format across the team.

    line 155
  20. Very specific:

    Keep model and operation naming aligned with OpenAPI (operationId and schema names) to avoid duplicate contracts.

    line 165

≈ “Common” is an estimate: at least 1 in 5 of the 16,597 AGENTS.md files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
AGENTS.md

Juniors Best Practice

Version 1.0.0
siberiacancode
February 2026

Note:
This document is optimized for agents and LLMs working on junior-friendly React and TypeScript codebases. It emphasizes clarity, consistency, and practical guidance.


Abstract

Juniors-focused best practices for React and TypeScript projects, organized by practical scopes (JS, React, styling, devtools, and more). Each guide includes concise guidance and examples that help early-career developers write clear, consistent, and maintainable code.


Table of Contents

  1. Beginner Foundations

    • 1.1 Early return
    • 1.2 Avoid double negation
    • 1.3 Avoid unnecessary destructuring
  2. TypeScript

    • 2.1 TypeScript path alias naming
    • 2.2 Flat translation keys
  3. React

    • 3.1 React string props
    • 3.2 Children prop
    • 3.3 Scalable components
    • 3.4 Props typing
  4. Styling

    • 4.1 Classnames helper
    • 4.2 CSS selectors for component states
  5. Devtools

    • 5.1 Formatter and linter
    • 5.2 Sorting imports
    • 5.3 Single package manager
  6. Assets

    • 6.1 SVG assets
  7. Git

    • 7.1 Commit conventions
  8. REST
    • 8.1 REST scalability via abstractions
    • 8.2 REST naming from OpenAPI

1. Beginner Foundations

1.1 Early return

Use early returns to reduce nesting and keep control flow easy to read.

1.2 Avoid double negation

Prefer positive names to avoid confusing !isNotX conditions.

1.3 Avoid unnecessary destructuring

Avoid destructuring when it hurts clarity or creates renaming noise.

1.4 const vs let

Default to const and use let only for real mutation.

1.5 Nullish vs OR (?? vs ||)

Prefer ?? when falsy values like 0 or false are valid.

1.6 Avoid unnecessary return in arrow functions

Keep arrow functions concise by removing redundant return.

1.7 Uppercase constants

Use UPPER_CASE only for stable, application-level constants.

2. TypeScript

2.1 TypeScript path alias naming

Use aliases that avoid collisions with external packages.

2.2 Flat translation keys

Prefer flat translation keys to avoid deep nesting, reduce duplication, and simplify lookup in locale files.

3. React

3.1 React string props

Use string literals directly when no expression is needed.

3.2 Children prop

Use children for flexible composition and typing clarity.

3.3 Scalable components

Extend native element props to keep components flexible.

3.4 Props typing

Keep prop types nearby and readable.

4. Styling

4.1 Classnames helper

Use a helper like clsx for conditional class names.

4.2 CSS selectors for component states

Prefer CSS selectors for hover/disabled/focus styling.

5. Devtools

5.1 Formatter and linter

Use formatters and linters to keep code consistent.

5.2 Sorting imports

Keep imports ordered and grouped for readability.

5.3 Single package manager

Use one package manager and a single lock file.

6. Assets

6.1 SVG assets

Use SVGs as components for scalable, themeable icons.

7. Git

7.1 Commit conventions

Use a consistent commit message format across the team.

8. REST

8.1 REST scalability via abstractions

Separate transport logic from endpoint definitions so API clients stay reusable and scalable.

8.2 REST naming from OpenAPI

Keep model and operation naming aligned with OpenAPI (operationId and schema names) to avoid duplicate contracts.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.