const doc = createDocument(source, { inputFormat: "bitmark" });
const json = doc.openView({ outputFormat: "json", pretty: true });
jsonModel.setValue(json.output!);
editor.onDidChangeModelContent((e) => {
const update = doc.applyChanges(model.getVersionId(), e.changes.map(toLsp));
jsonModel.applyEdits(update.views[0].edits.map(toMonaco));
});
UnsupportedFeatureError on a variant built without the
document feature.
A handle on one text for an editor (PLAN-271). It re-converts only the bits an edit changes — JSON entries, markup elements — and answers each open view with the edits that turn its previous output into
convert's output for the new text, byte for byte.