Skip to content

Make codesnippets in the docs typechecked #32

@rpanic

Description

@rpanic

The rust node's documentation extracts code snippets in the docs from the actual codebase (or some derivative of it - not sure). This means that they are always typechecked and preferably part of some test that is also run during CI.

See https://o1-labs.github.io/mina-rust/docs/developers/referencing-code-in-documentation and https://o1-labs.github.io/mina-rust/docs/developers/ocaml-reference-tracking
And https://github.com/o1-labs/mina-rust/blob/develop/.github/workflows/docs.yaml#L54-L77
And https://github.com/o1-labs/mina-rust/blob/develop/.github/workflows/check-ocaml-refs.yaml

For us, a good end goal would be if during a protokit release, a workflow for the website is triggered, that compiles and runs the code snippets based on the new release, and then rebuilds and deploys itself. This means that we will receive errors as soon as the docs contain outdates code snippets

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

Status

In Progress

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions