Riksdagsmonitor Intelligence Platform โ€” API Documentation - v1.0.30
    Preparing search index...
    • Repair as many Mermaid blocks as the deterministic pipeline can handle. The file is rewritten in place when write is true and at least one block changed; otherwise the function only reports what would have changed (dry-run).

      Block-level repair workflow per file:

      1. Extract every block.
      2. For each block: if it currently parses, leave it alone. Otherwise run repairMermaidBlock once and re-parse. If the repaired body parses, splice it back into the file body. If it still fails, record the residual violation.
      3. Unclosed-fence blocks are also repaired by appending a synthetic ``` line at the implied end-of-block.

      Parameters

      • file: string
      • options: { write: boolean }

      Returns Promise<MermaidRepairResult>