Sub-project
cli
Problem
specs scan crashes with "Cannot create a string longer than 0x1fffffe8 characters" on large Figma files
Expected behavior
Manifest written to data/XYComponentLibrary.manifest.md
Actual behavior
Root cause (hypothesis): The CLI reads the entire .file.json payload into a single JS string before parsing. For very large files, this exceeds the V8 string length limit (~512MB). Switching to a streaming JSON parser (e.g. stream-json) or using JSON.parse on a Buffer instead of a decoded string would fix this.
Steps to reproduce
- Configure a source pointing to a large Figma component library XYComponentLibrary
- Run specs fetch --only XYComponentLibrary --no-geometry — download succeeds (file is ~500MB+ JSON)
- Run specs scan --source XYComponentLibrary
Acceptance criteria
No response
Additional context
Environment: Windows 11, Node.js v22.20.0, corporate network with TLS inspection
CLI version: 0.27.0
Sub-project
cli
Problem
specs scan crashes with "Cannot create a string longer than 0x1fffffe8 characters" on large Figma files
Expected behavior
Manifest written to data/XYComponentLibrary.manifest.md
Actual behavior
Root cause (hypothesis): The CLI reads the entire .file.json payload into a single JS string before parsing. For very large files, this exceeds the V8 string length limit (~512MB). Switching to a streaming JSON parser (e.g. stream-json) or using JSON.parse on a Buffer instead of a decoded string would fix this.
Steps to reproduce
Acceptance criteria
No response
Additional context
Environment: Windows 11, Node.js v22.20.0, corporate network with TLS inspection
CLI version: 0.27.0