Agent skill

Graph Dev

by gravity-ui in gravity-ui/graph

Development workflow for @gravity-ui/graph. An agent skill from gravity-ui/graph.

MITAuto-check passedTesting & QA

Install Graph Dev

skills CLI
$ npx skills add gravity-ui/graph --skill graph-dev -a claude-code

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

GitHub CLI
$ gh skill install gravity-ui/graph graph-dev --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/gravity-ui/graph.git skills-src && mkdir -p .claude/skills && cp -r skills-src/.claude/skills/graph-dev .claude/skills/graph-dev && 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
graph-dev
GitHub stars
144
Token cost
~1.8k tokens
SKILL.md length
912 words
Files
1
Skills in repo
1
Repo updated
First seen
Licence
MIT

At a glance

Development workflow for @gravity-ui/graph. An agent skill from gravity-ui/graph.

  • Works in 4 steps: Planning → DX/UX Analysis → Development → …
  • Implementing features
  • SKILL.md covers Phase 1: Planning, Phase 2: DX/UX Analysis, Phase 3: Development and Phase 4: Testing
  • Calls npm and npx

What it does

Graph Dev is an agent skill from gravity-ui/graph. Development workflow for @gravity-ui/graph. Use when implementing features, fixing bugs, or designing APIs in this library.

Its SKILL.md is about 1.8k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Testing & QA. The licence is MIT.

When your agent uses it

  • Implementing features
  • Designing APIs in this library

Example prompts

  • “/graph-dev”

Requirements

  • Node.js

Workflow steps

4 steps, taken from the step headings in SKILL.md.

  1. Planning
  2. DX/UX Analysis
  3. Development
  4. Testing

What it can do on your machine

Read from SKILL.md and the folder at commit c2cfc79. 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

    Shell commands in SKILL.md call:

    • npm
    • npx

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

  • Network

    No URLs in SKILL.md. Its commands use npm and npx, which can reach the network depending on how they are called.

    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

Graph Dev loads about 1.8k tokens when it runs. Until then it costs about 33 tokens; SKILL.md has 912 words of instructions outside code blocks.

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

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

The full file from gravity-ui/graph at commit c2cfc79, republished under its MIT licence (© gravity-ui). 912 words, ~1,786 tokens.

Download SKILL.mdSave it as .claude/skills/graph-dev/SKILL.md (or your agent's skills folder).
name
graph-dev
description
Development workflow for @gravity-ui/graph. Use when implementing features, fixing bugs, or designing APIs in this library.
disable-model-invocation
true

@gravity-ui/graph Development Workflow

Follow these phases in order. Skip to Phase 3 only for trivial one-line fixes.


Phase 1: Planning

Before writing any code, understand what you are touching. Read the relevant source files. Use EnterPlanMode for non-trivial features.

Architecture questions to answer:

  1. Which layers are affected?

    Before deciding where to add or change something, discover all existing layers in the codebase:

    • Search src/ for classes that extend Layer to get the current full list
    • For each candidate layer, read its source to understand its zIndex, purpose, and what events it handles

    Identify the right layer:

    • Does an existing layer already do something close? Extend or modify it rather than creating a new one.
    • Is it purely visual without interaction? → probably GraphLayer or a new Canvas-only layer
    • Is it an HTML overlay? → use the html property in Layer constructor with transformByCameraPosition: true
    • Is it a new user interaction (drag, click, keyboard)? → check whether it fits into an existing interaction layer or needs a dedicated one

    If the task specifies which layer to use: read that layer's source, understand what it currently does, and verify the fit. If the specified layer seems wrong (wrong zIndex, wrong responsibility, event conflicts with existing handlers), raise the concern and clarify with the user before starting.

  2. How do events propagate?

    • User input → which layer catches it? → which service processes it? → which store signals change? → which components re-render?
    • Are there events that need to be preventable via executеDefaultEventAction?
  3. What are the data boundaries?

    • Store (RootStore, signals) — single source of truth
    • Canvas components read from store, never own authoritative state
    • React components sync via $viewComponent signal bridge
  4. Does it touch the scheduler?

    • All Canvas rendering goes through the scheduler (RAF-batched)
    • Don't call render() directly — always performRender()
    • React updates are synchronous (via signals), Canvas updates are deferred
  5. Are there circular dependency risks?

    • affectsUsableRect: false on HitBox to break cycles with boundary elements
    • Layers must not depend on each other directly

Output of this phase: A written plan with affected files, implementation approach, and potential risks.


Phase 2: DX/UX Analysis

After planning, forecast how the feature will be used — before writing a single line.

Developer Experience (DX)
  • How does a library consumer configure this feature? Is the API consistent with existing patterns (e.g., graph.addLayer(MyLayer, props), graph.setEntities(...), useGraphEvent)?
  • Are there footguns? (e.g., forgetting to call super.afterInit(), wrong coordinate space)
  • Does it require boilerplate that could be hidden inside the library?
User Experience (UX)
  • What does the end user see and feel?
  • Are there edge cases that could produce unexpected visual behavior?
  • Does interaction feel responsive (correct z-index stacking, correct hit regions)?
Critical rule

If a clean DX or UX requires compromises from the library — complexity, performance regressions, or incorrect behavior — eliminate the compromises, even at the cost of DX/UX.

The library is correct and performant first. API ergonomics are secondary. A footgun that the consumer can avoid with documentation beats a footgun baked into the library internals.

Output of this phase: A brief written DX/UX assessment. If you identified a tradeoff, explicitly state which side you chose and why.


Show full SKILL.md (398 more words)Show less

Phase 3: Development

Follow the conventions from CLAUDE.md. Key rules:

  • No any type — use concrete types, void, or unknown
  • State: setState()/setProps() not direct assignment; performRender() not render()
  • Layers: DOM ops only in afterInit(), never in constructor or init()
  • Events: AbortController via layer wrapper methods (onGraphEvent, onCanvasEvent, etc.)
  • Children: Component.create(props) not new Component(props); return from updateChildren()
  • Signals: wrap multiple signal writes in batch(() => { ... })
  • Coordinates: components receive world coordinates; canvas transform handles screen conversion

Phase 4: Testing

Choose the right test type for each concern.

Unit tests — isolated logic, no graph rendering

Write a Jest unit test when the code under test:

  • Is a pure function or utility (src/utils/)
  • Is a service or store class that can be instantiated without a real Graph object
  • Does not require simulating user events on a real canvas
  • Does not require a running scheduler or animation frame loop

Examples: HitTest, IncrementalBoundingBoxTracker, coordinate math, store selectors, BatchPath2DRenderer.

bash
npm run test
npm run test -- <pattern>         # run specific test file
E2e tests — user interactions and visual behavior

Add an e2e test to the test suite when the fix or feature requires:

  • User interaction (click, drag, hover, keyboard)
  • Visual verification (z-index stacking, cursor changes, rendering output)
  • Camera/zoom behavior
  • setEntities lifecycle with real block components rendered in the browser

E2e tests live in e2e/tests/. Use GraphPageObject and its Component Object Models.

bash
npm run e2e:bundle                 # REQUIRED after any source change
npm run e2e                        # run all e2e tests
npx playwright test <pattern>      # run specific test

Always run npm run e2e:bundle before npm run e2e if you changed TypeScript source. The e2e server must be on port 6006. Kill Storybook first if it's running there.

Self-checking during development

While implementing, write a temporary e2e test for yourself to verify that the code behaves as you expect before considering the task done. This is your development feedback loop, not a final test.

Rules for self-check tests:

  • Place them in e2e/tests/ alongside other tests — run them, iterate, confirm behavior
  • Once verified, decide: does this test cover something the permanent suite should guard? If yes, clean it up and keep it. If it's purely scaffolding for your own debugging, delete it.
  • Never leave temporary assertions, console.log calls, or debugging helpers in GraphPageObject, GraphBlockComponentObject, GraphConnectionComponentObject, or other shared POM/COM files. These files are the stable API for all tests — keep them clean. Add methods to them only if they are genuinely reusable.
What not to unit-test

Don't write a unit test if the assertion would require:

  • Mocking CanvasRenderingContext2D in a non-trivial way
  • Faking the scheduler loop
  • Simulating pointer events on a canvas element

Use e2e for those cases instead.

© gravity-ui, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in .claude/skills/graph-dev of gravity-ui/graph.

Open the folder on GitHubat commit c2cfc79

Compare with similar skills

Graph Dev 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.

Graph Dev compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Graph Dev this skillgravity-ui/graph144—~1.8kAutomated safety check: PassMIT
Web Application Testinganthropics/skills180k51 repos~966Automated safety check: PassApache-2.0
Diagnosing Bugsfossasia/eventyay-interpretation1.6k32 repos~2.1kAutomated safety check: PassApache-2.0
TDDpietheinstrengholt/rssmonster56430 repos~906Automated safety check: PassMIT
TDD WorkflowhellangleZ/burn-in-cceverywhere-ralph11211 repos~2.4kAutomated safety check: PassNone
TDDsanity-io/sanity6.4k20 repos~1kAutomated safety check: PassMIT

Similar skills

  • Web Application Testing

    anthropics/skills

    Official

    Tests local web applications with Python Playwright scripts, checking frontend behavior, capturing screenshots and reading browser console logs.

    180k GitHub starsUsed in 51 repos~966 tokens
    Testing & QAAuto-check passed
  • Diagnosing Bugs

    fossasia/eventyay-interpretation

    Diagnosis loop for hard bugs and performance regressions. An agent skill from fossasia/eventyay-interpretation.

    1.6k GitHub starsUsed in 32 repos~2.1k tokens
    Testing & QAAuto-check passed
  • TDD

    pietheinstrengholt/rssmonster

    Test-driven development. An agent skill from pietheinstrengholt/rssmonster.

    564 GitHub starsUsed in 30 repos~906 tokens
    Testing & QAAuto-check passed
  • TDD Workflow

    hellangleZ/burn-in-cceverywhere-ralph

    A skill your agent uses when writing new features, fixing bugs, or refactoring code.

    112 GitHub starsUsed in 11 repos~2.4k tokens
    Testing & QAAuto-check passed
  • TDD

    sanity-io/sanity

    Official

    Test-driven development with red-green-refactor loop. An agent skill from sanity-io/sanity.

    6.4k GitHub starsUsed in 20 repos~1k tokens
    Testing & QAAuto-check passed
  • Context Driven Development

    Ibrahim-3d/orchestrator-supaconductor

    A skill your agent uses when working with Conductor's context-driven development methodology, managing project context artifacts, or understanding the relationship between product.md, tech-stack.md…

    381 GitHub starsUsed in 9 repos~2.9k tokens
    Testing & QAAuto-check passed

Categories

Questions about Graph Dev

What does Graph Dev do?

Development workflow for @gravity-ui/graph. An agent skill from gravity-ui/graph. Graph Dev is an agent skill from gravity-ui/graph. Development workflow for @gravity-ui/graph.

When should I use Graph Dev?

Graph Dev fits situations like: implementing features; designing APIs in this library.

How do I install Graph Dev in Claude Code?

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

How do I install Graph Dev in Codex?

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

Can I use Graph Dev 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 gravity-ui/graph --skill graph-dev -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/graph-dev, .gemini/skills/graph-dev, .github/skills/graph-dev and .opencode/skills/graph-dev in your project.

What does Graph Dev need to run?

Going by SKILL.md and its folder, Graph Dev needs the command-line tools its instructions call (npm and npx). Our summary lists: Node.js.

Does Graph Dev access the network?

SKILL.md contains no URLs. Its commands use npm and npx, which can reach the network depending on how they are called. This is read from the text; nothing was executed.

Is Graph Dev 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 Graph Dev use?

Graph Dev is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Graph Dev use?

About 1.8k tokens (SKILL.md is roughly 7.1k 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 Graph Dev?

Skills that share tags, products or a category with Graph Dev: Web Application Testing (anthropics/skills, 180k stars), Diagnosing Bugs (fossasia/eventyay-interpretation, 1.6k stars), TDD (pietheinstrengholt/rssmonster, 564 stars) and TDD Workflow (hellangleZ/burn-in-cceverywhere-ralph, 112 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Graph Dev?

gravity-ui (a GitHub organization) maintains it in gravity-ui/graph, which has 144 GitHub stars. The repository was last updated on October 8, 2026.

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