Agent skill

LobeHub TypeScript Style Guide

by lobehub in lobehub/lobehub

House rules for TypeScript type safety, async code and imports in the LobeHub codebase, covering inference, error suppression, module augmentation and IO patterns.

Custom licenceAuto-check passedDevelopment

Install LobeHub TypeScript Style Guide

skills CLI
$ npx skills add lobehub/lobehub --skill typescript -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install lobehub/lobehub typescript --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/lobehub/lobehub.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.agents/skills/typescript .claude/skills/typescript && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
typescript
GitHub stars
83k
Token cost
~968 tokens
SKILL.md length
475 words
Files
1
Skills in repo
50
Repo updated
First seen
Licence
Custom licence

At a glance

House rules for TypeScript type safety, async code and imports in the LobeHub codebase, covering inference, error suppression, module augmentation and IO patterns.

  • Writing or reviewing TypeScript code in the LobeHub repository
  • SKILL.md covers Types and Type Safety, Async Patterns, Imports and Code Structure, plus 2 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md
  • Deciding between an interface and a type for a new shape

What it does

This skill sets the TypeScript conventions to follow when editing .ts, .tsx or .mts files in LobeHub. On types, it favors letting TypeScript infer over explicit annotations, bans implicit any, prefers `Record<PropertyKey, unknown>` over object or any, uses interface for object shapes like React props and type for unions, and ranks `@ts-expect-error` above `@ts-ignore` above `as any`. Extensible types get a small mergeable interface at the source that each feature augments locally, rather than one central registry file.

On async code it requires IO at module boundaries to use promise-based APIs such as `fs/promises`, never `*Sync` by default, because a sync-to-async rewrite later forces changing every caller, while the reverse is never needed. The only accepted uses of `*Sync` are call sites locked inside an existing synchronous contract or sync-only callbacks like `process.on('exit')`; module load time and CLI startup should use top-level await instead. Imports are left to lint rules for import sorting and separate type-only import statements.

When your agent uses it

  • Writing or reviewing TypeScript code in the LobeHub repository
  • Deciding between an interface and a type for a new shape
  • Choosing between a sync and an async API for new IO code
  • Making an existing type extensible without a central registry

Example prompts

  • “Review this new service module for TypeScript style issues before I open a PR.”
  • “Should this new file reader use readFileSync or the promises API?”
  • “How should I let plugins extend the PipelineContext metadata type without one giant registry file?”

Requirements

  • The LobeHub repository with its lint configuration

What it can do on your machine

Read from SKILL.md and the folder at commit 1863542. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md.

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

LobeHub TypeScript Style Guide loads about 968 tokens when it runs. Until then it costs about 32 tokens; SKILL.md has 475 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~32
When it runs · the whole SKILL.md, loaded when a task matches
~968

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

Its licence (Custom licence) doesn't allow us to republish the file, so here is its outline and opening line. It has 475 words (~968 tokens).

name
typescript
user-invocable
false

Read the full SKILL.md on GitHub

Files

Just SKILL.md in .agents/skills/typescript of lobehub/lobehub.

Open the folder on GitHubat commit 1863542

Compare with similar skills

LobeHub TypeScript Style Guide next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

LobeHub TypeScript Style Guide compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
LobeHub TypeScript Style Guide this skilllobehub/lobehub83k—~968Automated safety check: PassCustom licence
Obsidian Plugin Development Guidelinesgapmiss/obsidian-plugin-skill190—~4.5kAutomated safety check: PassMIT
Strict Programming Practicescode-yeongyu/oh-my-openagent70k—~9.5kAutomated safety check: PassCustom licence
Fallow Setupfallow-rs/fallow-skills129—~1.1kAutomated safety check: PassMIT
No Bare Castsprisma/orm48k—~705Automated safety check: PassApache-2.0
Typescript Best Practicesjwynia/agent-skills165—~2.5kAutomated safety check: PassMIT

Similar skills

  • Obsidian Plugin Development Guidelines

    gapmiss/obsidian-plugin-skill

    Rules and references for building Obsidian plugins: ESLint rules, TypeScript practices, memory cleanup, API choices, UI standards and the community submission process.

    190 GitHub stars~4.5k tokensUpdated 12 days ago
    DevelopmentAuto-check passed
  • Strict Programming Practices

    code-yeongyu/oh-my-openagent

    Applies strict, type-first coding rules for Python, Rust, TypeScript and Go, loading the matching language reference before the agent writes or edits any code.

    70k GitHub stars~9.5k tokensUpdated today
    DevelopmentAuto-check passed
  • Fallow Setup

    fallow-rs/fallow-skills

    Set up or modernize code-quality tooling for JavaScript and TypeScript projects.

    129 GitHub stars~1.1k tokensUpdated today
    DevelopmentAuto-check passed
  • No Bare Casts

    prisma/orm

    Official

    Replaces bare `as` casts in production TypeScript with a decision tree of tighter types, type predicates, satisfies and audited cast helpers.

    48k GitHub stars~705 tokensUpdated today
    DevelopmentAuto-check passed
  • Typescript Best Practices

    jwynia/agent-skills

    Guide AI agents through TypeScript coding best practices including type safety, error handling, code organization, and architecture patterns.

    165 GitHub stars~2.5k tokensUpdated 7 mo ago
    DevelopmentAuto-check passed
  • Neo4j Driver Javascript Skill

    neo4j-contrib/neo4j-skills

    Neo4j JavaScript/TypeScript Driver v6 — driver lifecycle, executeQuery, managed transactions (executeRead/executeWrite), session.run, Integer handling, JSON serialization, record access, async/await…

    114 GitHub stars~3.5k tokensUpdated today
    DevelopmentAuto-check: notes

More from lobehub/lobehub

All 50 skills in this repo
  • Builds single-file interactive HTML prototypes rendered with the real LobeHub UI components and written as production-style React, so they can later be split into files.

    83k GitHub stars~1.6k tokensUpdated today
    Auto-check passed
  • Verifies a delivery end to end by driving the real product on a CLI, web, desktop or iOS Simulator surface, capturing evidence and publishing a round with the lh CLI.

    83k GitHub stars~9.7k tokensUpdated today
    Auto-check passed
  • Git Worktree Cleanup

    lobehub/lobehub

    Audits stale Git worktrees and branches with a bundled script, classifies each one, and deletes only after you approve the exact candidates.

    83k GitHub stars~2.8k tokensUpdated today
    Auto-check passed
  • Maintains LobeHub's model-backed alint rule set: writing rules, removing false positives against real code, deciding warn versus error and tracking token cost.

    83k GitHub stars~1.9k tokensUpdated today
    Auto-check passed
  • Guides building LobeHub builtin agent tools, from the manifest and execution runtime to executors, chat UI renders and registry wiring.

    83k GitHub stars~2.4k tokensUpdated today
    Auto-check passed
  • Explains how LobeHub client code fetches data through services, SWR store hooks and cache keys, and when to avoid useEffect fetching or duplicated state.

    83k GitHub stars~1.7k tokensUpdated today
    Auto-check passed

Works with

Categories

Questions about LobeHub TypeScript Style Guide

What does LobeHub TypeScript Style Guide do?

House rules for TypeScript type safety, async code and imports in the LobeHub codebase, covering inference, error suppression, module augmentation and IO patterns. mts files in LobeHub. On types, it favors letting TypeScript infer over explicit annotations, bans implicit any, prefers `Record<PropertyKey, unknown>` over object or any, uses interface for object shapes like React props and type for unions, and ranks `@ts-expect-error` above `@ts-ignore` above `as any`.

When should I use LobeHub TypeScript Style Guide?

LobeHub TypeScript Style Guide fits situations like: writing or reviewing TypeScript code in the LobeHub repository; deciding between an interface and a type for a new shape; choosing between a sync and an async API for new IO code; making an existing type extensible without a central registry.

How do I install LobeHub TypeScript Style Guide in Claude Code?

Run `npx skills add lobehub/lobehub --skill typescript -a claude-code`. Or copy the skill folder (.agents/skills/typescript in lobehub/lobehub) into .claude/skills/typescript in your project. Claude Code loads it when a task matches its description.

How do I install LobeHub TypeScript Style Guide in Codex?

Run `npx skills add lobehub/lobehub --skill typescript -a codex`. Or copy the skill folder (.agents/skills/typescript in lobehub/lobehub) into .agents/skills/typescript in your project. Codex loads it when a task matches its description.

Can I use LobeHub TypeScript Style Guide in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add lobehub/lobehub --skill typescript -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/typescript, .gemini/skills/typescript, .github/skills/typescript and .opencode/skills/typescript in your project.

What does LobeHub TypeScript Style Guide need to run?

SKILL.md names no scripts, command-line tools or credentials: LobeHub TypeScript Style Guide is instructions for the agent only. Our summary lists: The LobeHub repository with its lint configuration.

Does LobeHub TypeScript Style Guide access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is LobeHub TypeScript Style Guide safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does LobeHub TypeScript Style Guide use?

LobeHub TypeScript Style Guide has a licence file (the repository's licence) that doesn't match a standard licence. Read it on GitHub before reusing the skill.

How many tokens does LobeHub TypeScript Style Guide use?

About 968 tokens (SKILL.md is roughly 3.9k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to LobeHub TypeScript Style Guide?

Skills that share tags, products or a category with LobeHub TypeScript Style Guide: Obsidian Plugin Development Guidelines (gapmiss/obsidian-plugin-skill, 190 stars), Strict Programming Practices (code-yeongyu/oh-my-openagent, 70k stars), Fallow Setup (fallow-rs/fallow-skills, 129 stars) and No Bare Casts (prisma/orm, 48k stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains LobeHub TypeScript Style Guide?

lobehub (a GitHub organization) maintains it in lobehub/lobehub, which has 83,023 GitHub stars. The repository holds 50 skills in this directory. The repository was last updated on October 7, 2026.

Source: lobehub/lobehub on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.