parse Scrapbox notation to JavaScript Object
$ npm i @progfay/scrapbox-parser
Also, you can install @progfay/scrapbox-parser
via JSR.
import { parse } from "@progfay/scrapbox-parser";
const PROJECT_NAME = "help";
const PAGE_NAME = "syntax";
fetch(`https://scrapbox.io/api/pages/${PROJECT_NAME}/${PAGE_NAME}/text`)
.then((response) => response.text())
.then((text) => parse(text));