Find every ^id block marker in text and return { id, body }
pairs in source order. body is the line content with the trailing
^id stripped (handy for previews). Duplicate IDs (the user
accidentally writing the same ^id twice) are de-duplicated; only
the first occurrence is kept.
Marker shape: ^[a-zA-Z0-9_-]+ at end of line. Same form
crossnote's transformer produces for ^id source markers, and the
form the host should write when generating new IDs.
Find every
^idblock marker intextand return{ id, body }pairs in source order.bodyis the line content with the trailing^idstripped (handy for previews). Duplicate IDs (the user accidentally writing the same^idtwice) are de-duplicated; only the first occurrence is kept.Marker shape:
^[a-zA-Z0-9_-]+at end of line. Same form crossnote's transformer produces for^idsource markers, and the form the host should write when generating new IDs.