How rossoandoy/figjson works
Project type and purpose
• This is an open-source conversion tool (“Figma to eDocument Converter”) that runs both as a browser-based web app (hosted via GitHub Pages) and as a Node.js command-line utility.
• Its sole purpose is to take a JSON export from Figma and transform it into a JSON format importable by Salesforce eDocument, with options for paper size, orientation, preview, and precision mapping.
File structure
• Top-level assets and entry points
– index.html, styles.css, app.js, converter-browser.js → the static web UI.
– figma-to-edocument-converter.js → the core converter engine exposed as a CLI module.
– package.json → Node.js metadata, scripts (“npm run convert”), dependencies.
– test-converter.js, edocument-test.js → automated tests validating conversion logic.
• Documentation and workflow
– README.md, Figjson_conversion_workflow.md, DEVLOG.md → usage, internal workflow, dev notes.
• Build / deploy
– No server-side back end: the browser version is purely client-side JS; CLI is pure Node.js.
README for additional insights
• There are two runtime environments:
• Browser: real-time preview + UI control.
• CLI: file in → file out.
• Key architectural goals: environment-agnostic core, separation of UI vs conversion logic, extension points for new element types.
Elements
• UI → Core → Renderer → UI download
• CLI → Core → File System
• Test Suite → Core
• Green for runtime components (UI, CLI)
• Blue for core conversion engine
• Gray for tests / docs
• Orange for external services (GitHub Pages, NPM)