Skip to content

Commit afcee0f

Browse files
committed
docs: improve react devtools performance routing
1 parent 37804bd commit afcee0f

4 files changed

Lines changed: 17 additions & 11 deletions

File tree

skills/react-devtools/SKILL.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
name: react-devtools
3-
description: Inspect and profile React Native component trees from agent-device. Use when debugging React Native props, state, hooks, render causes, slow components, excessive rerenders, or questions like why a component rerendered.
3+
description: Inspect and profile React Native component trees from agent-device. Use for React Native performance, profiling, props, state, hooks, render causes, slow components, excessive rerenders, or questions like why a component rerendered.
44
---
55

66
# react-devtools
@@ -11,7 +11,7 @@ Router for React Native internals. Read current CLI guidance:
1111
agent-device help react-devtools
1212
```
1313

14-
Use `agent-device react-devtools ...` for component tree, props, state, hooks, render ownership, slow components, or rerenders. It dynamically runs pinned `agent-react-devtools@0.4.0`. Use normal `agent-device` commands for visible UI, refs, screenshots, logs, network, or perf.
14+
Use `agent-device react-devtools ...` for component tree, props, state, hooks, render ownership, performance profiling, slow components, or rerenders. It dynamically runs pinned `agent-react-devtools@0.4.0`. Use normal `agent-device` commands for visible UI, refs, screenshots, logs, network, or device-level perf.
1515

1616
Core loop:
1717

src/__tests__/cli-help.test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ test('help react-devtools prints agent workflow topic and skips daemon dispatch'
4848
assert.equal(result.code, 0);
4949
assert.equal(result.calls.length, 0);
5050
assert.match(result.stdout, /agent-device help react-devtools/);
51-
assert.match(result.stdout, /React Native internals/);
51+
assert.match(result.stdout, /React Native performance\/profiling/);
5252
assert.match(result.stdout, /agent-device react-devtools status/);
5353
});
5454

src/utils/__tests__/args.test.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -793,7 +793,10 @@ test('usage includes agent workflows, config, environment, and examples footers'
793793
assert.match(usageText, /Agent Workflows:/);
794794
assert.match(usageText, /help workflow\s+Normal bootstrap, exploration, and validation loop/);
795795
assert.match(usageText, /help debugging\s+Logs, network, alerts, diagnostics, and traces/);
796-
assert.match(usageText, /help react-devtools\s+React Native component tree and render profiling/);
796+
assert.match(
797+
usageText,
798+
/help react-devtools\s+React Native performance, profiling, component tree, and renders/,
799+
);
797800
assert.match(usageText, /Configuration:/);
798801
assert.match(
799802
usageText,

src/utils/command-schema.ts

Lines changed: 10 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -161,7 +161,10 @@ const FIND_SNAPSHOT_FLAGS = ['snapshotDepth', 'snapshotRaw'] as const satisfies
161161
const AGENT_WORKFLOWS = [
162162
{ label: 'help workflow', description: 'Normal bootstrap, exploration, and validation loop' },
163163
{ label: 'help debugging', description: 'Logs, network, alerts, diagnostics, and traces' },
164-
{ label: 'help react-devtools', description: 'React Native component tree and render profiling' },
164+
{
165+
label: 'help react-devtools',
166+
description: 'React Native performance, profiling, component tree, and renders',
167+
},
165168
{ label: 'help remote', description: 'Remote config, tenants, leases, and companion tunnels' },
166169
{ label: 'help macos', description: 'Desktop, frontmost-app, and menu bar surfaces' },
167170
{ label: 'help dogfood', description: 'Exploratory QA report workflow' },
@@ -295,7 +298,7 @@ React DevTools minimum loop:
295298
296299
Escalate:
297300
help debugging logs, network, alerts, traces, flaky runtime failures
298-
help react-devtools props, state, hooks, component tree, slow renders, rerenders
301+
help react-devtools React Native performance, profiling, props/state/hooks, slow renders, rerenders
299302
help remote remote-config, tenant, lease, remote Android companion tunnel
300303
help macos desktop, frontmost-app, menu bar surfaces
301304
help dogfood exploratory QA report workflow`,
@@ -346,13 +349,13 @@ Stabilizers:
346349
Re-enable settings you changed before finishing.
347350
348351
React Native internals:
349-
If the question is about props, state, hooks, render causes, slow components, or rerenders, use help react-devtools instead of inferring from screenshots or logs.`,
352+
If the question is about React Native performance, profiling, props, state, hooks, render causes, slow components, or rerenders, use help react-devtools instead of inferring from screenshots or logs.`,
350353
},
351354
'react-devtools': {
352-
summary: 'React Native component tree and profiling workflow',
355+
summary: 'React Native performance, profiling, and component internals',
353356
body: `agent-device help react-devtools
354357
355-
Use this for React Native internals that the accessibility tree cannot expose: components, props, state, hooks, ownership, slow renders, and rerenders.
358+
Use this for React Native performance/profiling and internals that the accessibility tree cannot expose: components, props, state, hooks, ownership, slow renders, and rerenders.
356359
357360
Core commands:
358361
agent-device react-devtools status
@@ -1507,8 +1510,8 @@ const COMMAND_SCHEMAS: Record<string, CommandSchema> = {
15071510
usageOverride: 'react-devtools [...args]',
15081511
listUsageOverride: 'react-devtools [...args]',
15091512
helpDescription:
1510-
'Run pinned agent-react-devtools commands for React Native component trees, props/state/hooks, and render profiling',
1511-
summary: 'Inspect and profile React Native component trees',
1513+
'Run pinned agent-react-devtools commands for React Native performance profiling, component trees, props/state/hooks, and render analysis',
1514+
summary: 'Profile React Native performance and component renders',
15121515
positionalArgs: ['args?'],
15131516
allowsExtraPositionals: true,
15141517
allowedFlags: [],

0 commit comments

Comments
 (0)