electron-flamegraph
Installation
SKILL.md
Electron Flamegraph: Setup & Analysis
Route to exactly one phase. Do not load the other phase's reference unless the user asks to continue into it.
Setup a capture
Use when the user has not produced a .cpuprofile yet.
- Inspect
package.json, Electron tooling config, and the main-process entry to identify the launcher, language, bundling, and source-map behavior. - Read
references/setup-patterns.md, but only the strategy and launcher sections that apply. - Choose whole-process
--cpu-profwhen there is no specific hypothesis, programmatic scoped profiling when one operation is suspected, or live--inspectfor interactive capture. Default to scoped profiling for a concrete operation and whole-process profiling otherwise. - Produce the exact launcher-specific command. For scoped profiling, add or adapt the helper in the project's style and show the precise call to wrap.
- Tell the user where the profile will land and what scenario to reproduce, then stop and wait for the resulting file path. Do not execute the interactive profiling command.
Analyze a capture
Use when the user provides a .cpuprofile path. Read references/analysis-workflow.md and follow it completely. Run the bundled scripts/analyze-cpuprofile.mjs from this skill directory rather than recreating its analysis.