neo-typescript
Skill7 starsChanged 6 months agoMITView on GitHub
Use this skill when writing, reviewing, debugging, or architecting TypeScript code. Trigger for tsconfig/compiler options, strict mode, generics, conditional/mapped/template literal types, structural typing, ESM/CJS interop, decorators, library typing, or TypeScript runtime boundary issues.
In this repository28 other files it gives its agents.
- AGENTS.mdAGENTS.md
- generate-skillSkill
- neo-azure-pipelinesSkill
- neo-clarificationSkill
- neo-clean-architectureSkill
- neo-code-reviewSkill
- neo-csharp-interface-generatorSkill
- neo-csharpSkill
- neo-dotnet-ef-coreSkill
- neo-dotnet-minimal-apisSkill
- neo-dotnet-mvcSkill
- neo-dotnetSkill
- neo-dotnet-tag-helperSkill
- neo-dotnet-webapiSkill
- neo-harness-projectSkill
- neo-harnessSkill
- neo-javascriptSkill
- neo-opentelemetrySkill
- neo-prSkill
- neo-python-managerSkill
- neo-pythonSkill
- neo-rabbitmqSkill
- neo-rustSkill
- neo-stop-slopSkill
- neo-sub-agentSkill
- neo-swiftSkill
- neo-swift-uiSkill
- neo-vueSkill
The file
We split this skill into the rules it gives an agent
2 rules. About 0 are common, 2 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈2
Distinctive · estimate
This author's own choices. Worth a look.
0
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 25
When asked to write, modify, refactor, or review TypeScript code, strictly execute the following workflow:
- Distinctive: line 38
Ensure all generated or modified code strictly adheres to the loaded reference guidelines (e.g., never declare optional callback …
≈ “Common” is an estimate: at least 1 in 5 of the 372,429 skill 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.
Files
Neo TypeScript Expert Skill
This skill guides the AI Agent to write code that adheres to the strictest type safety, high maintainability, and advanced meta-programming flexibility, while thoroughly preventing runtime issues such as ESM/CJS interoperability pitfalls.
💡 Gotchas
- Aliasing Writable Reference Bypasses Readonly: In TypeScript,
readonlyonly restricts the assignment to the property itself. The internal members of the referenced object/array remain mutable. Furthermore, a readonly object can be assigned to a writable alias, which completely bypasses compiler readonly checks. - Fatal Crash via Partial esModuleInterop: Enabling
allowSyntheticDefaultImportswithoutesModuleInteropallows code to pass compile-time type checks but causes an immediate runtime crash (TypeError: default is not a function) due to the lack of__importDefaultemit helpers in transpile output. - Double Default Trap for Library Creators: Using
export defaultin libraries forces Node.js ESM consumers to call.default()to access the module. The golden standard is to completely abandonexport defaultand adoptexport =or named exports instead.
📋 Static Code & Type Safety Review SOP
When asked to write, modify, refactor, or review TypeScript code, strictly execute the following workflow:
Step 1 — Project Environment Perception (Perceive)
- Inspect the project's
tsconfig.jsonsettings, focusing specifically on the configuration of"strict": true,"strictNullChecks", and"strictFunctionTypes". - Identify the target module format and resolution mechanism (
"moduleResolution").
Step 2 — Core Type Routing (Reason)
Based on the specific technical domain of the task, progressively disclose and load the corresponding reference files in the skill. Do not load all files at once to save context token space:
- Basics, Narrowing, Classes, & Function Design ➡️ Load type-system-basics.md
- Generic Constraints, Variance, & Advanced Types from Types ➡️ Load advanced-meta-types.md
- Structural Compatibility, Decorators, & ESM/CJS Interop ➡️ Load compatibility-and-interop.md
Step 3 — Precise Code Generation & Review (Act)
- Ensure all generated or modified code strictly adheres to the loaded reference guidelines (e.g., never declare optional callback parameters, ensure generic type parameters appear at least twice to establish correlation).
- For advanced type generation, recommend clear unit test assertions based on the evals configuration.
🛠️ Available Resources (Relative Paths)
- Type System Basics Guide
- Advanced Meta Types Guide
- Compatibility and Interop Guide
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
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.

