ban-type-assertions
This skill enables the TypeScript ESLint rule that bans `as` type assertions in a package, replacing them with compiler-verified alternatives like Zod…
Identity proven by GitHub's verified organisation badge (Factory-AI)
- Agents
- Claude Code, Codex, Cursor, Gemini CLI, GitHub Copilot, OpenCode, claude.ai and API
- License
- No license stated
- Pin
- 7166a07pinned Oct 9, 2026
- Context cost
- about 1,600 tokenswhen the skill loads
- GitHub stars
- 110on factory-ai/factory-plugins
- Scripts
- None found
What it does
“Ban `as` type assertions in a package via the `@typescript-eslint/consistent-type-assertions` lint rule, replacing them with compiler-verified type-safe alternatives. Use when enabling the assertion ban in a new package or fixing violations in an existing one.”
Generated summary from the skill's own text
This skill enables the TypeScript ESLint rule that bans `as` type assertions in a package, replacing them with compiler-verified alternatives like Zod parsing, control flow narrowing, or type guards. It guides developers through a systematic workflow to identify violations and fix them using a tiered approach that prioritizes runtime validation over unverified casts.
When to use it
- Adopting strict type safety in a new package with TypeScript
- Enforcing compiler-verified types instead of developer assertions
- Adding runtime validation at data boundaries like JSON parsing
- Fixing existing type assertion violations systematically across a codebase
When not to
- When library types genuinely cannot be inferred or narrowed
- For projects that accept developer assertions as a reasonable tradeoff
- If replacing assertions with equally unverified type guards
Install
No license stated: install from the publisher's repository, and ask the author before you reuse or share it.
These commands install from the publisher's repository and need no account.
skills CLI
npx skills add factory-ai/factory-plugins --skill ban-type-assertionsInstalls from the repository's default branch, which may have changed since the commit we checked.
GitHub CLI 2.90 or later
gh skill install factory-ai/factory-plugins ban-type-assertions@7166a0799e3dd39184068160b9caaa1e6469028aInstalls the commit we checked (7166a07).
Copy by hand
Download the folder at 7166a07 and put it in .claude/skills/ban-type-assertions for Claude Code and in .agents/skills/ban-type-assertions for Codex, Cursor, Gemini CLI, GitHub Copilot and OpenCode.
Copy for your agent
A prompt for any coding agent. It installs this skill from GitHub at the pinned commit, copies the files as they are, and runs nothing unless you ask.
Prompt
Install the agent skill "ban-type-assertions" by Factory. Source, pinned to commit 7166a0799e3dd39184068160b9caaa1e6469028a: https://github.com/factory-ai/factory-plugins/tree/7166a0799e3dd39184068160b9caaa1e6469028a/plugins/typescript/skills/ban-type-assertions 1. Download that folder at exactly this commit. Do not use the default branch. 2. Copy every file unchanged, keeping the folder structure, into .claude/skills/ban-type-assertions/ for Claude Code and .agents/skills/ban-type-assertions/ for Codex, Cursor, Gemini CLI, GitHub Copilot and OpenCode. Create the folders if they do not exist. 3. Do not edit the files, and do not run any script in the folder unless I ask you to. 4. When you are done, list the files you copied and where you put them. Its license is restricted or not stated. Show me the license terms from the repository before you copy anything. Listing and checks: https://www.agentnative.dev/skills/factory/ban-type-assertions
SKILL.md at the pin
The license of this skill does not let us show its files here.
Files
- SKILL.md6.9 KB · 622aff26a012
1 file, 6.9 KB in total. Each file has a sha256 in the pin's manifest; the first 12 characters are shown.
Skill folder on GitHub at 7166a07More from Factory
autoresearch
This skill runs an autonomous optimization loop to improve a measurable metric through systematic experimentation.
Contains scripts
Claude Code, Codex, Cursor +3 · about 4K tokens · pinned 6 days ago
browser-navigation
This skill enables agents to automate browser interactions including navigation, form filling, element clicking, screenshots, and data extraction from web…
Claude Code, Codex, Cursor +3 · about 2.5K tokens · pinned 6 days ago
create-pr
Creates a pull request with Conventional Commits formatting, templated body, and optional ticket linking.
Claude Code, Codex, Cursor +4 · about 2.2K tokens · pinned 6 days ago
droid-control
Automate terminals, browsers, and desktop applications by routing to specialized drivers for recording, testing, and generating visual demonstrations.
Claude Code · about 3.5K tokens · pinned 6 days ago
fix-knip-unused-exports
Fixes knip unused export violations by identifying their type (test-only, dead barrel re-export, or internally-only-used) and applying the appropriate fix…
Claude Code, Codex, Cursor +4 · about 2.4K tokens · pinned 6 days ago
follow-up-on-pr
This skill takes over an existing pull request, rebases it on the latest base branch, addresses reviewer feedback with code changes, runs local CI checks, and…
Claude Code, Codex, Cursor +4 · about 1.4K tokens · pinned 6 days ago
Related in Coding workflow
no-bare-casts
This skill enforces a decision tree for TypeScript casts, requiring developers to eliminate bare `as` casts through type refinement, runtime checks, or using…
by PrismaOfficial publisher
Claude Code, Codex, Cursor +4 · about 650 tokens · pinned 6 days ago
coding-workspace-fixture
This skill lets the agent evaluate and modify a small TypeScript project located in the coding-workspace-fixture directory.
by SentryOfficial publisher
Contains scripts
Claude Code, Codex, Cursor +3 · about 56 tokens · pinned 6 days ago
datadog-app
This skill guides developers building Datadog Apps with TypeScript, React, and the scaffolder toolchain.
by DatadogOfficial publisher
Claude Code, Codex, Cursor +4 · about 610 tokens · pinned 6 days ago
practice-registry
This skill checks Scala, Python, TypeScript, JavaScript, and Rust code against company-specific coding practices before generation, during editing, and before…
by WriterOfficial publisher
Claude Code, Codex, Cursor +4 · about 410 tokens · pinned 6 days ago
typescript-lsp
This skill provides TypeScript Language Server Protocol integration to search and explore TypeScript/JavaScript codebases by symbols, types, and references.
by You.comOfficial publisher
Claude Code, Codex, Cursor +4 · about 1.6K tokens · pinned 6 days ago
appscript
This skill enables agents to develop, edit, push, and deploy Google Apps Script projects using the clasp CLI from the terminal.
by SMKeramatiCommunity
Claude Code, Codex, Cursor +4 · about 3.3K tokens · pinned 6 days ago
Open roles at Factory
5 of 7 open roles on the jobs board
- Solutions Engineer, Enterprise, West
San Francisco, CA, USA (On-site)
- Member of Deployed Staff
San Francisco, CA, United States (On-site)
- Software Engineer, Platform
San Francisco, CA, USA (On-site)
- Research Engineer
San Francisco, CA, USA (On-site)
- Software Engineer, Deployed
San Francisco, CA, USA (On-site)