devtools
できること
このスキルは、Reactの表をTanStack Devtoolsのパネルに登録する方法を示します。開発者は作りながら表を確認できます。設定、必要なキー、後片付けを扱います。
使う場面
- ✓Reactの表がdevtoolsパネルにない場合に、その登録を直す必要があるとき。
- ✓開発中にアプリを動かしながら、Reactの表の状態を調べたいとき。
- ✓devtoolsのフックを、条件分岐で呼ばず、Reactのルールに従わせる必要があるとき。
スキルのリンク
https://github.com/TanStack/table/blob/main/packages/react-table-devtools/skills/devtools/SKILL.mdコピーしてAI(Claude、ChatGPT、Cursor)に貼り付け、指示に従うよう頼んでください。
使い方
いちばん簡単な方法:メッセージをコピーしてAIに貼り付けるだけ。AIがスキルを読んで指示に従います。
貼り付け用メッセージ
Claude Code、Codex、Cursorの場合:プロジェクトのフォルダで実行するとスキルがインストールされます。
SKILL.mdをダウンロードして、エージェントのスキル用フォルダに入れてください。
AIへの頼み方の例
“なぜ私のReactの表がTanStackのdevtoolsパネルに表示されないのですか?”
毎週5つの新しいスキル。1分で読めます。
仕組み
表に一意のキーを付け、表を作った直後に登録のフックを呼び出します。そして、アプリのルート近くにdevtoolsのホストを1つ追加する方法を説明します。
技術的な内容(元のSKILL.md)
作者による元のテキスト(英語)をGitHubからそのまま表示しています。
This skill builds on @tanstack/table-core#core and @tanstack/table-devtools#devtools.
Setup
import { TanStackDevtools } from '@tanstack/react-devtools'
import { useTable, tableFeatures } from '@tanstack/react-table'
import {
tableDevtoolsPlugin,
useTanStackTableDevtools,
} from '@tanstack/react-table-devtools'
const features = tableFeatures({})
const columns = [{ accessorKey: 'id' }]
const data: Array<{ id: string }> = []
export function App() {
const table = useTable({
key: 'users-table',
features,
columns,
data,
})
useTanStackTableDevtools(table)
return <TanStackDevtools plugins={[tableDevtoolsPlugin()]} />
}
Hooks and Components
Use useTanStackTableDevtools(table, { enabled }) immediately after creating the table. Mount one TanStackDevtools host with tableDevtoolsPlugin() near the application root.
Common Mistakes
HIGH Hook receives a keyless table
Wrong: create the table without key and expect the hook to infer a name.
Correct: set a unique key in table options before calling the hook.
Core target registration skips keyless tables.
Source: TanStack/table:docs/devtools.md
HIGH Hook called conditionally
Wrong: call useTanStackTableDevtools only inside an if branch.
Correct: call it every render and pass { enabled: condition }.
The hook owns React effect registration and cleanup.
Source: TanStack/table:packages/react-table-devtools/src/useTanStackTableDevtools.ts
MEDIUM Default import expected in production
Wrong: expect the normal hook/plugin/panel to inspect production tables.
Correct: keep normal guidance development-only; use the /production entrypoint only when explicitly required.
The default index selects no-op implementations outside development.
Source: TanStack/table:packages/react-table-devtools/src/index.ts
API Discovery
Inspect node_modules/@tanstack/react-table-devtools/dist/index.d.ts and useTanStackTableDevtools.d.ts for the installed lifecycle API.
よくある質問
なぜdevtoolsに表がスキップされるのですか?
キーのない表はスキップされるので、フックを呼ぶ前に一意のキーを設定するようスキルは述べています。
devtoolsの登録のオン・オフを切り替えられますか?
はい、ifの分岐の中だけで呼ぶのではなく、フックにenabledのオプションを渡してください。
devtoolsのホストはどこに置きますか?
アプリのルートの近くに一度置き、そこに表のdevtoolsのプラグインを追加します。
詳細
作者による元の説明
Connect React Table v9 instances to Devtools with tableDevtoolsPlugin and useTanStackTableDevtools. Load for missing Table panels, registration lifecycle, required options.key, enabled state, or development versus explicit production exports.
repo: TanStack/table
人気
- GitHubのスター
- 29k
- ランキング
- #9823
- ライセンス
- MIT
- 更新日
- 2026/10/21
コメント
- …
このリポジトリの他のスキル
getting-started
29kエージェントが、Alpine.jsでTanStack Tableを使ってデータテーブルを作り、表示する方法を教えます。セットアップ、リアクティブなデータ、行の描画を扱います。
table-state
29kエージェントが、Alpine.jsで表の状態(現在のページなど)を読み取り、制御する方法を教えます。その状態が変わると、画面が更新されます。
devtools
29kエージェントが、Angularの表をTanStack Devtoolsのパネルに登録する方法を教えます。開発者はアプリを作りながら、各表を調べられます。
getting-started
29kエージェントが、AngularでTanStack Tableの表を作り、表示する方法を教えます。injectTableの設定、テンプレートの描画、行データの更新を扱います。
似ているスキル
angular-developer
280kエージェントがAngularのコードを作成し、プロジェクト構成についてアドバイスできるようにします。新しいプロジェクトの開始、コード部品の作成、パフォーマンスやアクセシビリティの改善に役立ちます。
frontend-a11y
280kエージェントが Web インターフェースを誰にとっても使いやすくするよう支援します。スクリーンリーダーやキーボード操作に対応し、サイトやアプリが適切に動作するようにします。
frontend-patterns
280kエージェントがフロントエンド開発の最新パターンを適用できるようにします。React と Next.js において、パフォーマンスの最適化、状態管理、ベストプラクティスの遵守を行います。