Writing emdash docs

From emdash-cms/emdash · View interactive version

Writing emdash docs is an AI agent skill from the GitHub repository emdash-cms/emdash. Write, revise, and review EmDash documentation for technical accuracy, useful structure, house style, and natural prose. Use when working on user documentation, guides, API reference pages, migration or upgrade guides, READMEs, contributor documentation, technical specifications, or release notes in

How to use this skill

Skill file

Writing EmDash docs

Produce documentation that helps a specific reader complete a task or understand a concrete part of EmDash. Treat factual accuracy, information design, and sentence-level style as separate checks.

Load the right context

Load only the context needed for the artifact:

  1. Read AGENTS.md for repository-wide rules.
  2. For public documentation, read docs/src/content/docs/contributing/docs-style-guide.mdx completely.
  3. Read references/docs-practice.md when creating or restructuring a page, changing a task path, reviewing accessibility or information architecture, or writing substantial examples.
  4. Read references/anti-slop.md for prose-heavy revisions, de-slopping, or humanization. A small factual correction does not require loading it.
  5. Read nearby pages of the same type to preserve established structure, terminology, frontmatter, imports, and Starlight component usage.
  6. Inspect the implementation, types, tests, command help, or configuration that establishes every technical claim. Do not rely on memory when the repository can answer the question.
  7. For changesets, read .changeset/README.md completely. Treat the entry as public CHANGELOG documentation and review whether affected readers can recognize the surface, understand the observable effect, and act on any migration guidance. Frontmatter validity and technical accuracy do not make an unhelpful entry acceptable.

Define the reader and outcome

State the intended outcome privately in one sentence: "After reading this, the reader can ..." Use it to decide what belongs on the page.

Classify the document before choosing its structure:

| Document | Reader need | Default shape |

| --------------------------- | -------------------------------------------- | -------------------------------------------------------------------------------------------------------------- |

| Tutorial | Learn through a reliable, guided experience | Visible goal, prerequisites, one path, expected results after each stage, recap |

| Task guide | Complete one practical task | Outcome, prerequisites, ordered actions, result, optional next step |

| Concept or explanation | Build an accurate mental model | Definition, relevant behavior, concrete example, implications |

| Reference | Look up exact behavior | Signature or syntax, parameters, defaults, return value, errors, examples |

| Troubleshooting | Diagnose and resolve a known failure | Exact symptom, context, cause or diagnostic checks, workaround or resolution, verification |

| Upgrade or migration guide | Make an existing project work after a change | Previous behavior, current behavior, required action, minimal diff |

| README or contributor guide | Start or contribute quickly | Short purpose, fastest working path, common operations, deeper links |

| Technical specification | Evaluate and implement a decision | Goal, constraints, decision, interfaces and data flow, failure handling, rollout, verification, open decisions |

Do not force every section into the same size. Give common or risky tasks more space than incidental details.

Draft for the task

For public docs, describe how to use EmDash. Put internal design detail in contributor or architecture documentation unless it changes a reader's decision.

Run the anti-slop pass

For a prose-heavy revision, finish the content pass before polishing sentences. Then inspect every changed paragraph using references/anti-slop.md. For a narrow factual correction, apply the same judgment without loading or mechanically running the full reference.

Ask of each sentence:

  1. Is it stating information or staging a reveal?
  2. Does it name the actor, behavior, and consequence precisely?
  3. Does it add information the reader needs?
  4. Does it preserve the source's meaning, uncertainty, and scope?

Remove chatbot residue, generic promotion, manufactured drama, self-grading, process narration, diff-centered language, and empty transitions. Replace vague emphasis with facts. Do not add anecdotes, measurements, opinions, dates, citations, or guarantees merely to make prose sound more human.

Treat pattern lists as prompts for judgment, not lexical bans. Keep a contrast when the reader is likely to hold the wrong model. Keep a hedge when evidence is limited. Keep repeated terminology when it prevents ambiguity.

Review the whole document

Read the finished page in order after reviewing the diff.

When asked for an audit only, report prioritized, concrete findings without editing. Otherwise, make the edits and summarize only material changes.

Verify

Run the narrowest checks that cover the changed artifact. Common checks include:

pnpm lint:quick
pnpm --dir docs build
git diff --check

Use the docs build for public docs, docs configuration, or shared content consumed by that build; do not run it merely because another Markdown file changed. Validate skill frontmatter and relative links when editing skills. Use additional tests when code samples or generated reference material depend on executable behavior.

If validation fails because declaration output is missing, run the root build and retry. Treat a remaining failure as introduced by the current work rather than establishing a pre-edit failure baseline.

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.