← c4studio · This site was generated by c4 publish from the model of c4studio itself.

Dynamic – typing a change and seeing it

Dynamic – typing a change and seeing itDeveloper[Person]Keeps the model honest alongsidethe code, usually in the same pullrequest.DSL Editor[Component: CodeMirror 6]CodeMirror 6 surface: highlighting,completion and lint marks over thebuffer.API Client[Component: TypeScript]One typed fetch wrapper perendpoint, so error handling and theURL scheme live in one place.API Routes[Component: FastAPI]The HTTP surface: sources, views,graphs, layout, check, save, files,templates, capabilities.Workspace Loader[Component: Python]Loads a workspace and watches its!include fragments by mtime. Afailed reload keeps serving the lastgood one.Source Writer[Component: Python]Atomic writes with content-hashfingerprints, so an edit madeelsewhere is a conflict rather than asilent overwrite. Invalid DSL still…Workspace Sources[Container: Files on disk]The user's .dsl and .json files,including !include fragments. Thesource of truth; c4studio nevergenerates them from the model.App Shell[Component: React]Owns the loaded workspace, theselected view, capabilities and thelive-reload poll.React Flow Reshape[Component: Python]Turns the view graph into thenode/edge payload the SPA draws,and attaches saved waypoints,labels and chrome.View Graph[Component: Python]Workspace + view -> nodes andedges, with C4 visibility, boundarynesting and endpoint lifting applied.The one contract every renderer…Graph Pane[Component: React, React Flow]The interactive diagram: drag,zoom, drill in, align, export. Prop-injected for its backend, which iswhat lets it be embedded…1. Types in the editor2. Debounced check of theunsaved buffer3. POST /api/check4. Parses the buffer in itsroot's context5. Presses Cmd+S6. PUT /api/source7. Writes atomically,fingerprint checked8. Replaces the file9. Reloads synchronously andreturns the generation10. Refetches the view11. GET /api/views/{key}/graph12. Rebuilds the payload13. From the reparsedworkspace14. RedrawsPersonComponentFile StoreRelationship