[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6BXG88RT3SN6B8RNFP01Q1J":3,"skill-same:01M6BXG88RT3SN6B8RNFP01Q1J":85},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":23,"publishedAt":32,"linkOnly":33,"markdownContent":34,"markdownBody":35,"frontMatter":36,"refName":40,"commitSha":41,"skillDirectory":42,"forksCount":43,"repositoryHtmlUrl":44,"repositoryHomepageUrl":6,"ownerHtmlUrl":45,"ownerBlogUrl":46,"ownerDescription":47,"updatedAt":48,"install":49,"resources":62},"01M6BXG88RT3SN6B8RNFP01Q1J","rerender",null,"Runs a real re-render benchmark on every React component in a project and renders a Lighthouse-style light-theme performance report. For each component it mounts the real code in jsdom inside a React Profiler, forces a fixed number of parent re-renders with stable props, and counts the renders React could have skipped (wasted renders) plus render durations, then scores each component 0-100. Use when the user runs \u002Frerender or asks to measure, benchmark, or find React re-render \u002F wasted-render \u002F memoization performance problems.","diegopacheco\u002Fai-playground","diegopacheco","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F121278?v=4","01M6BXCP8P7GGSJ8M1W2MFDTGT","Diego Pacheco","01M6BXCPD3WM51H465XW9YM4BV",21,"Unlicense","https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fagent-skill-react-rerender\u002Fskills\u002Frerender\u002FSKILL.md",[18],{"categoryNo":19,"categoryName":20,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000009","前端开发","SCENARIO","使用场景",[5,24,25,26,27,28,29,30,31],"performance","react","component","code","benchmark","report","Lighthouse","Bash","2026-11-10 10:12:30",false,"---\nname: rerender\ndescription: Runs a real re-render benchmark on every React component in a project and renders a Lighthouse-style light-theme performance report. For each component it mounts the real code in jsdom inside a React Profiler, forces a fixed number of parent re-renders with stable props, and counts the renders React could have skipped (wasted renders) plus render durations, then scores each component 0-100. Use when the user runs \u002Frerender or asks to measure, benchmark, or find React re-render \u002F wasted-render \u002F memoization performance problems.\nallowed-tools: [Bash, Read, AskUserQuestion]\n---\n\n# React Re-render Performance\n\nWhen invoked, you measure how every React component in a project behaves under parent re-renders and render a light-theme, Lighthouse-style website that scores each component 0-100. The engine bundles a harness with the project's **own React**, mounts each component in **jsdom** inside a `\u003CProfiler>`, re-renders its parent a fixed number of times with **referentially-stable props**, and uses React's `onRender` callback to count the re-renders that did real work despite unchanged props — the wasted renders that `React.memo` would skip — plus mount and per-render durations.\n\n## Global Context\n- User request \u002F scope: $ARGUMENTS — empty, or a path to the React project root\n- Engine: `scripts\u002Frerender.mjs` (Node; only dependencies are esbuild and jsdom, installed beside the skill)\n- Template: `assets\u002Ftemplate.html`\n- Output: `rerender-report\u002Findex.html` and `rerender-report\u002Fdata.json` in the current directory\n\n## Rules\n- Every number is **measured at runtime, never estimated**. If the engine cannot mount a component, it records that component as not-measured rather than inventing numbers.\n- Read-only against the project. The skill only writes inside `rerender-report\u002F` (and a `.rerender-tmp\u002F` it deletes when done).\n- The engine needs the project's `node_modules` (it mounts the project's real React and components). If they are missing, it cannot run.\n- Do not add comments to any command you run.\n\n## Step 1 — Find the project\nDecide the target from `$ARGUMENTS`:\n- A path to a directory → that is the project root.\n- Empty → use the current working directory.\n\nConfirm it is a React project: a `package.json` exists and `react` is installed under `node_modules`. The engine scans `src\u002F` if present, otherwise the project root, for `.jsx\u002F.tsx` (and React-flavored `.js\u002F.ts`) component files, skipping `node_modules`, build output, tests, stories, and the entry file that calls `createRoot`\u002F`hydrateRoot`.\n\n## Step 2 — Make sure dependencies are installed\nThe harness mounts the project's real React, so its dependencies must resolve:\n\n```bash\ntest -d \u003Cproject>\u002Fnode_modules\u002Freact && echo present || echo missing\n```\n\nIf missing, tell the user the engine needs an install first and offer to run it:\n\n```bash\nnpm --prefix \u003Cproject> install\n```\n\n## Step 3 — Run the benchmark engine\nInvoke the engine by its installed absolute path. It always writes `rerender-report\u002F` into the current working directory, so run it from where you want the report. Pass the project root:\n\n```bash\ncd \u003Cproject> && node \"$HOME\u002F.claude\u002Fskills\u002Frerender\u002Fscripts\u002Frerender.mjs\" .\n```\n\nThe engine discovers the components, statically analyses each (memoization, hooks, inline props, array work in render), then bundles and runs the measurement harness once. It prints a per-component summary to stdout and writes the full report. If it cannot bundle the project (path aliases, exotic loaders) it explains why — relay that instead of producing a partial report.\n\n## Step 4 — Report back\nRelay the stdout summary in your own words: the overall score, how many components are clean vs. wasting renders, the total wasted renders out of stressed updates, and the slowest component. Name the components that scored poorly and the one-line fix for each (wrap in `React.memo`, move heavy work into `useMemo`, stop passing inline object\u002Farray\u002Ffunction props). Point the user at the generated site:\n\n```\nrerender-report\u002Findex.html\n```\n\nOffer to open it. The page is self-contained — an overall score gauge, animated metric counters, a wasted-renders bar chart, a score distribution, an average-render-cost chart, and a sortable\u002Ffilterable card per component with its score, metrics, a per-render sparkline, and concrete fixes — no server or network needed.\n\n## What the numbers mean\n- **Wasted renders** — under N parent re-renders with unchanged props, the count of re-renders that still did measurable work. A correctly memoized component bails out and scores 0; an un-memoized one re-renders every time. This is the headline re-render lens.\n- **Avg \u002F peak ms** — `actualDuration` from React's Profiler. Measured in a React **development profiling build** (required for the Profiler to report timings), so absolute values run a little high but are honest and comparable across components.\n- **Score** — 0-100, Lighthouse-style: green ≥90, orange 50-89, red \u003C50. Driven mainly by the wasted-render ratio, plus render cost and static anti-patterns.\n- **Root component** — the one rendered by `createRoot` has no real parent, so it is measured for mount cost only and exempt from the wasted-render test.\n","# React Re-render Performance\n\nWhen invoked, you measure how every React component in a project behaves under parent re-renders and render a light-theme, Lighthouse-style website that scores each component 0-100. The engine bundles a harness with the project's **own React**, mounts each component in **jsdom** inside a `\u003CProfiler>`, re-renders its parent a fixed number of times with **referentially-stable props**, and uses React's `onRender` callback to count the re-renders that did real work despite unchanged props — the wasted renders that `React.memo` would skip — plus mount and per-render durations.\n\n## Global Context\n- User request \u002F scope: $ARGUMENTS — empty, or a path to the React project root\n- Engine: `scripts\u002Frerender.mjs` (Node; only dependencies are esbuild and jsdom, installed beside the skill)\n- Template: `assets\u002Ftemplate.html`\n- Output: `rerender-report\u002Findex.html` and `rerender-report\u002Fdata.json` in the current directory\n\n## Rules\n- Every number is **measured at runtime, never estimated**. If the engine cannot mount a component, it records that component as not-measured rather than inventing numbers.\n- Read-only against the project. The skill only writes inside `rerender-report\u002F` (and a `.rerender-tmp\u002F` it deletes when done).\n- The engine needs the project's `node_modules` (it mounts the project's real React and components). If they are missing, it cannot run.\n- Do not add comments to any command you run.\n\n## Step 1 — Find the project\nDecide the target from `$ARGUMENTS`:\n- A path to a directory → that is the project root.\n- Empty → use the current working directory.\n\nConfirm it is a React project: a `package.json` exists and `react` is installed under `node_modules`. The engine scans `src\u002F` if present, otherwise the project root, for `.jsx\u002F.tsx` (and React-flavored `.js\u002F.ts`) component files, skipping `node_modules`, build output, tests, stories, and the entry file that calls `createRoot`\u002F`hydrateRoot`.\n\n## Step 2 — Make sure dependencies are installed\nThe harness mounts the project's real React, so its dependencies must resolve:\n\n```bash\ntest -d \u003Cproject>\u002Fnode_modules\u002Freact && echo present || echo missing\n```\n\nIf missing, tell the user the engine needs an install first and offer to run it:\n\n```bash\nnpm --prefix \u003Cproject> install\n```\n\n## Step 3 — Run the benchmark engine\nInvoke the engine by its installed absolute path. It always writes `rerender-report\u002F` into the current working directory, so run it from where you want the report. Pass the project root:\n\n```bash\ncd \u003Cproject> && node \"$HOME\u002F.claude\u002Fskills\u002Frerender\u002Fscripts\u002Frerender.mjs\" .\n```\n\nThe engine discovers the components, statically analyses each (memoization, hooks, inline props, array work in render), then bundles and runs the measurement harness once. It prints a per-component summary to stdout and writes the full report. If it cannot bundle the project (path aliases, exotic loaders) it explains why — relay that instead of producing a partial report.\n\n## Step 4 — Report back\nRelay the stdout summary in your own words: the overall score, how many components are clean vs. wasting renders, the total wasted renders out of stressed updates, and the slowest component. Name the components that scored poorly and the one-line fix for each (wrap in `React.memo`, move heavy work into `useMemo`, stop passing inline object\u002Farray\u002Ffunction props). Point the user at the generated site:\n\n```\nrerender-report\u002Findex.html\n```\n\nOffer to open it. The page is self-contained — an overall score gauge, animated metric counters, a wasted-renders bar chart, a score distribution, an average-render-cost chart, and a sortable\u002Ffilterable card per component with its score, metrics, a per-render sparkline, and concrete fixes — no server or network needed.\n\n## What the numbers mean\n- **Wasted renders** — under N parent re-renders with unchanged props, the count of re-renders that still did measurable work. A correctly memoized component bails out and scores 0; an un-memoized one re-renders every time. This is the headline re-render lens.\n- **Avg \u002F peak ms** — `actualDuration` from React's Profiler. Measured in a React **development profiling build** (required for the Profiler to report timings), so absolute values run a little high but are honest and comparable across components.\n- **Score** — 0-100, Lighthouse-style: green ≥90, orange 50-89, red \u003C50. Driven mainly by the wasted-render ratio, plus render cost and static anti-patterns.\n- **Root component** — the one rendered by `createRoot` has no real parent, so it is measured for mount cost only and exempt from the wasted-render test.\n",{"name":5,"description":7,"allowed-tools":37},[31,38,39],"Read","AskUserQuestion","main","90d379e95fcc23dd9759654c345424e1752b0f3a","pocs\u002Fagent-skill-react-rerender\u002Fskills\u002Frerender",9,"https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground","https:\u002F\u002Fgithub.com\u002Fdiegopacheco","http:\u002F\u002Fdiego-pacheco.blogspot.com","Brazilian Hands-on Software Architect | 20+ years in Tech | Author | Father. Opinions are my own!","2026-11-15 01:01:48",{"source":8,"skillName":5,"commands":50,"prompt":60,"zipAvailable":61},[51,54,57],{"tool":52,"command":53},"npx","npx skills add diegopacheco\u002Fai-playground --skill rerender",{"tool":55,"command":56},"bunx","bunx skills add diegopacheco\u002Fai-playground --skill rerender",{"tool":58,"command":59},"pnpm","pnpm dlx skills add diegopacheco\u002Fai-playground --skill rerender","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fagent-skill-react-rerender\u002Fskills\u002Frerender\u002FSKILL.md",true,[63,69,75,79],{"path":64,"resourceType":65,"resourceTypeDesc":66,"sizeBytes":67,"sourceHtmlUrl":68},"assets\u002Ftemplate.html","ASSET","资产文件",22953,"https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fagent-skill-react-rerender\u002Fskills\u002Frerender\u002Fassets\u002Ftemplate.html",{"path":70,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":73,"sourceHtmlUrl":74},"package-lock.json","REFERENCE","参考文档",32477,"https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fagent-skill-react-rerender\u002Fskills\u002Frerender\u002Fpackage-lock.json",{"path":76,"resourceType":71,"resourceTypeDesc":72,"sizeBytes":77,"sourceHtmlUrl":78},"package.json",166,"https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fagent-skill-react-rerender\u002Fskills\u002Frerender\u002Fpackage.json",{"path":80,"resourceType":81,"resourceTypeDesc":82,"sizeBytes":83,"sourceHtmlUrl":84},"scripts\u002Frerender.mjs","SCRIPT","脚本",17638,"https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fagent-skill-react-rerender\u002Fskills\u002Frerender\u002Fscripts\u002Frerender.mjs",[86,102,112,125,141,159],{"skillNo":87,"name":88,"nameZh":6,"description":89,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":90,"categories":91,"keywords":95,"publishedAt":32},"01M6WJ537DN520XY8MSW9ZV0RP","word-count","Counts the words, lines and characters of a text or a file.","https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fskills-gateway-router\u002Fupstream-skills\u002Ftext-skills\u002Fword-count\u002FSKILL.md",[92],{"categoryNo":93,"categoryName":94,"taxonomyType":21,"taxonomyTypeDesc":22},"01JBSEEDCAT000000000000002","文档处理",[96,97,98,99,100,101],"count","word count","Word","characters","text","file",{"skillNo":103,"name":104,"nameZh":6,"description":105,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":106,"categories":107,"keywords":108,"publishedAt":32},"01M6WJ4Y2GT5SECWAKKYHGES4F","slugify","Turns a title or a sentence into a URL slug, lowercase words joined by hyphens with accents removed.","https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fskills-gateway-router\u002Fupstream-skills\u002Ftext-skills\u002Fslugify\u002FSKILL.md",[],[104,109,110,111],"title","with","URL",{"skillNo":113,"name":114,"nameZh":6,"description":115,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":116,"categories":117,"keywords":118,"publishedAt":32},"01M6WJ4V9CWHT9NVCD441VK5MH","json-format","Validates a JSON file and pretty prints it with two space indentation, or reports where the JSON is invalid.","https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fskills-gateway-router\u002Fupstream-skills\u002Fdev-skills\u002Fjson-format\u002FSKILL.md",[],[119,120,121,101,122,123,124,110],"json","format","json format","reports","invalid","it",{"skillNo":126,"name":127,"nameZh":6,"description":128,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":129,"categories":130,"keywords":131,"publishedAt":32},"01M6WJ4QMRKW8EFP71F4KS2DHE","commit-message","Writes a conventional commit message for the staged git changes.","https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fskills-gateway-router\u002Fupstream-skills\u002Fdev-skills\u002Fcommit-message\u002FSKILL.md",[],[132,133,134,135,136,137,138,139,140],"commit","commit message","message","git","conventional commit","for","changes","staged","conventional commit message",{"skillNo":142,"name":143,"nameZh":6,"description":144,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":145,"categories":146,"keywords":147,"publishedAt":32},"01M6WJ4MAM2CJH0GWYXFBB9GQC","skills-gateway","Gateway and router to a catalog of skills that are not registered directly. Use it before any task a specialized skill could handle, such as text, JSON or git chores. It finds the right skill and loads its instructions.","https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fskills-gateway-router\u002F.claude\u002Fskills\u002Fskills-gateway\u002FSKILL.md",[],[148,149,124,150,151,135,31,119,100,152,153,154,155,156,157,158],"skills gateway","gateway","task","loads","node","specialized","instructions","catalog","use","router","as",{"skillNo":160,"name":161,"nameZh":6,"description":162,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":163,"categories":164,"keywords":165,"publishedAt":32},"01M6M2PYJJQKMWGX7XT7ZJK0H3","decision-log","Record, list, show and supersede architecture decisions that persist across sessions in the shared agent infra state store. Use when the user says \"record this decision\", \"log an ADR\", \"what did we decide about\", \"list decisions\", or \"supersede decision\".","https:\u002F\u002Fgithub.com\u002Fdiegopacheco\u002Fai-playground\u002Fblob\u002Fmain\u002Fpocs\u002Fagent-skills-infra-poc\u002Fskills\u002Fdecision-log\u002FSKILL.md",[],[166,167,168,169,170,171,172,173,174,175,156,176,177,178,179,180,181,182,183,184],"decision log","log","decision","persist","architecture","state","adr","decide","decisions","list","show","infra","record","across","shared","store","about","supersede","sessions"]