Reference
CLI
Every command and flag of the prongs CLI. Generated from the same data as prongs --help.
Run it with npx prongs, or through your package manager’s scripts. It needs Node 22.18 or newer: it loads your TypeScript registry with Node’s built-in type stripping.
Commands
prongs add
Copy the UI components and starter intents into your repo, and write prongs.json.
--dirWhere the components go. Defaults to components/prongs.
<path>--forceOverwrite files that already exist.
flag
npx prongs addprongs add gallery
Add a page that renders every intent in your registry live (development only by default).
--routeWhere to put the page in a Next.js app. Defaults to app/prongs/page.tsx.
<file>--publicServe the page in production too.
flag
prongs add logs
Add the logs profile: audit, security, incident, job and debug intents, plus log().
prongs add errors
Add the errors profile: request, auth, permission, record, conflict, limit and failure intents, plus fail(). Adds the logs profile too, which errors write to.
prongs add analytics
Add trackIntents(), which reports presses, submits, toggles and opens as events named by intent. You decide where they go.
prongs find <what it is for>
Look up the intents for a job: each match with what it renders, its "not for" lines and how code writes it.
--limitHow many matches to show (default 3).
<n>--jsonPrint the matches as JSON, for tools.
flag
npx prongs find "wrong email or password"prongs check [paths...]
Check how intents are used. Existing violations in the baseline pass; new ones fail.
--jsonPrint the findings as JSON, for tools.
flag--suggestGroup repeated overrides and styled raw elements into proposed intents.
flag--update-baselineRecord today’s findings in .prongs/baseline.json, so only new ones fail.
flag--no-baselineIgnore the baseline and report everything.
flag--max-unsafeFail when unsafeClassName is used more than n times.
<n>--hookRun as an agent hook: read the edited file from the hook payload and answer in that tool’s format.
claude | cursor
npx prongs check --suggestprongs add-intent <id>
Add an intent to the registry, validate it, and regenerate PRONGS.md. Rolls back if the registry would be invalid.
--descriptionRequired: what the intent is for, in a sentence.
"<what it is for>"--refsIntents to build it from.
a,b--classesUI intents: its own classes.
"..."--elementUI intents: the element it renders.
<tag>--not-forWhen not to use it.
"<context>"--insteadWhat to use in that case.
<id>
npx prongs add-intent action.follow --refs control.primary --description "Follows a person"prongs spec
Write PRONGS.md from the registry.
--outWhere to write it. Defaults to PRONGS.md.
<file>--agentsAlso add a short block to AGENTS.md, and make sure CLAUDE.md reaches it.
flag--checkWrite nothing; fail if PRONGS.md is out of date. For CI.
flag
npx prongs spec --agentsprongs export
Print the registry as JSON, in the shape the spec defines, for tools that do not run TypeScript.
--outWrite it to a file instead of printing it.
<file>
npx prongs export --out prongs.registry.jsonprongs install-hooks
Run prongs check on every file an agent edits.
--claudeOnly the Claude Code PostToolUse hook.
flag--cursorOnly the Cursor postToolUse hook.
flag
Common options
--configUse a config file other than ./prongs.json.
<prongs.json>--cliHow printed commands should call the CLI, e.g. "yarn prongs".
"<how to run prongs>"