dnd-kit-implementation

dnd-kit-implementation is a skill for Claude Code from atman-33/workhub. It costs 66 tokens per session (766 once invoked), scanned A, original, MIT.

An implementation guide for building React interfaces with dnd-kit that let users reorder containers and drop items into them.

In plain words
What is it for?
Use it for Kanban boards, file managers, and other React interfaces with sortable groups and drop targets.
Why use it?
It explains how to coordinate sorting and dropping so the same interface can handle both kinds of movement correctly.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the stack-dnd-kit plugin — 1 skill shipped together

Good fit Use it for Kanban boards, file managers, and other React interfaces with sortable groups and drop targets.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/atman-33/workhub/dnd-kit-implementation
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add atman-33/workhub --skill dnd-kit-implementation
Clone the repo
git clone --depth 1 https://github.com/atman-33/workhub

Made for: Claude Code.

Or install stack-dnd-kit, the plugin that ships this one along with the rest of its 1 skill.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for dnd-kit-implementation

README.md
[![agentmods](https://agentmods.dev/badge/skills/atman-33/workhub/dnd-kit-implementation/github.svg)](https://agentmods.dev/skills/atman-33/workhub/dnd-kit-implementation)
Your own site
<a href="https://agentmods.dev/skills/atman-33/workhub/dnd-kit-implementation"><img src="https://agentmods.dev/badge/skills/atman-33/workhub/dnd-kit-implementation/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for dnd-kit-implementation

Your own site · 80×15
<a href="https://agentmods.dev/skills/atman-33/workhub/dnd-kit-implementation"><img src="https://agentmods.dev/badge/skills/atman-33/workhub/dnd-kit-implementation.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 66 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 766 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00066 $0.00766
Opus 5 $0.00033 $0.00383
Sonnet 5 $0.00013 $0.00153
Haiku 4.5 $0.00007 $0.00077

Measured 6d ago against content hash 9aa08fd02e05, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

dnd-kit-implementation scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

plugins/stack-dnd-kit/skills/dnd-kit-implementation/SKILL.md · 108 lines

How it starts

The opening of the file, as written. The whole thing — 108 lines — stays where its author put it; the contents beside it link to each section on GitHub.

dnd-kit Implementation Guide

Overview

This skill provides patterns for implementing drag-and-drop functionality using dnd-kit library that supports both sortable containers and droppable targets simultaneously.

Core Concept

The key to combining useSortable and useDroppable is conditional logic based on drag context:

  • When dragging items → containers act as drop-only targets
  • When dragging containers → containers act as sortable elements

This is achieved by detecting what's currently being dragged and enabling only the appropriate functionality.

Implementation Pattern

Container Component Structure

const SortableDroppableContainer = ({ container }) => {
  // useSortable for container reordering
  const {
    attributes,
    listeners,
    setNodeRef: setSortableRef,
    transform,
    transition,
    isDragging,
  } = useSortable({ id: container.id });

  // useDroppable for receiving items
  const { setNodeRef: setDroppableRef, isOver } = useDroppable({
    id: container.id,
  });

  // Active element from context
  const { active } = useDndContext();

  // Determine behavior based on what's being dragged
  const isItem = active?.id?.toString().startsWith('item-');
  const isContainer = active?.id?.toString().startsWith('container-');

  // Apply conditional refs
  const setNodeRef = isItem ? setDroppableRef : setSortableRef;

  return (
    <div ref={setNodeRef} {...(isContainer ? attributes : {})} style={style}>
      <div {...(isContainer ? listeners : {})}>{/* Drag handle */}</div>
      {/* Container content */}
    </div>
  );
};

Key Implementation Points

  1. Dual Hook Usage: Use both useSortable and useDroppable in the same component
  2. Context Detection: Use useDndContext() to check what's being dragged
  3. Conditional Refs: Apply the appropriate ref based on drag state
  4. ID Naming Convention: Use prefixes like container-* and item-* to distinguish types

ID Naming Convention

// Containers
const containerId = `container-${id}`;

// Items
const itemId = `item-${id}`;

Read the full file on GitHub · 108 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 6d ago First seen · 108 lines · 66 tokens per session scan A 9aa08fd02e05

Subscribe to this mod's changes

dnd-kit-implementation is a skill published in the GitHub repository atman-33/workhub (2 stars, last pushed yesterday), licensed MIT. It adds 66 tokens to every session and 766 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-09-03.

Related

Other skills, from other repositories

frontend

Use when building React components, optimizing performance, analyzing bundle sizes, scaffolding projects, implementing accessibility, reviewing frontend code quality, performing visual overhauls, or designing UI/UX systems.

Joncik91/ucai · 40 tokens

nextjs-patterns

Next.js App Router — Server Components, Actions, streaming, caching. Use when building or migrating Next.js apps.

martineserios/thebrana · 28 tokens

react-patterns

React + TypeScript component and hook standards. TRIGGER when: creating components, custom hooks, or reviewing React code. SKIP: visual styling and theme tokens (use mui-styling); global store design (use state-management).

komluk/scaffolding · 51 tokens

fe-build

Implements frontend components and pages for React / Next.js / Vite SPA + TypeScript projects. Use when: starting implementation after feature.md or a spec is approved, writing components, building pages. Do NOT load for: writing specs, code review, bug analysis.

sh5623/fe-rail · 57 tokens

nextjs-ssr-patterns

Default command for population on a fresh worktree or after a git pull that includes a lockfile change: npm ci — lockfile-respecting, deterministic install. Run from the project root. This is the form CI workflows and Dockerfiles use. The bare npm install form is acceptable only when the lockfile is known-stale or for…

lukasrepublic/agentic-foundry · 0 tokens

vite-spa-patterns

Default command for population on a fresh worktree or after a git pull that includes a lockfile change: npm ci — lockfile-respecting, deterministic install. Run from the project root. This is the form CI workflows and Dockerfiles use. The bare npm install form is acceptable only when the lockfile is known-stale or for…

lukasrepublic/agentic-foundry · 0 tokens