Skip to main content
A project file is JSON text. It holds the building, the saved views and the sheets. saveProject writes the text and openProject reads it.

Import

Example

Notes

  • These functions do not use the disk or the network. Your app stores the text.
  • Put session.snapshot() into buildingModel before you save.
  • openProject checks the text. A problem throws ProjectFileError with a code and a path.
  • The file does not hold geometry, images or undo history. Floorkit builds them again after you open the file.
  • Files from earlier versions open.

saveProject

Validate and serialize one project, upgrading older BuildingModels without changing the input.

openProject

Parse and validate project JSON without reading from disk or compiling the building.

ProjectFileError

A storage-boundary error with a stable code and a path into the project JSON.

Types

ProjectFile

The durable project envelope.
'floorkit.project'
required
1 | 2 | 3
required
BuildingModel
required
SavedDrawingView[]
required
Named drawing definitions; each can later be placed on one or more sheets.
PaperDocument
required
readonly ProjectViewMarker[]
Plan markers refer to saved views; source geometry remains derived. Schema 3.

ProjectViewMarker

Markers belong to a saved plan.

ViewMarkerBase

The package does not export this type by name.

ViewMarkerTarget

A durable saved-view reference.
Last modified on October 11, 2026