Skip to content

🧱 Keep a single source of truth for the checklist content #36

Open
@shnizzedy

Description

@shnizzedy

I. This file vs. checklist.json

Is the idea to move away from the JSON-LD encoding in checklists/checklist.json or to have it also encoded in JSON schema?

If the former, I think we can replace checklist.json with this JSON.

If the latter, I think we should choose one encoding to maintain and write a CI or precommit script to handle the translation.

II. Checklist versioning

The current directory structure is with the idea that the checklist content will be versioned separately from the checklist interface. I think that's the right design, but I don't know how to do that without housing the schema in a sibling directory tree with its own package.json.

Depending on what the answers are to part I of this comment, this part could be moot if the JSON-LD sibling checklist is the source of truth that is translated into the JSON Schema checklist for the interface.

#30 (comment)

i) I think we could move this towards JSON-LD while still being JSON schema, but for now we wanted to be able to build and validate a form from the schema, so that was the tug towards the latter standard. ii) good question, not sure either; can we agree to resolve/further decouple later?

#30 (comment)

The current schema is already JSON-LD

flowchart LR
LD["JSON-LD"] --> UI
Loading

; this PR introduces a JSON Schema document as a separate, parallel source of truth.

flowchart LR
LD["JSON-LD"]
Schema["JSON Schema"] --> UI
Loading

I'm suggesting we keep the JSON-LD as the source of truth and autogenerate the JSON Schema for the UI from the JSON-LD

flowchart LR
LD["JSON-LD"] --automation--> Schema["JSON Schema"] --> UI
Loading

#30 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions