You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Attempting to modify the schema in src/schema.ts to add support for <hr> looks initially like it will work, but instead attempting to load a document with one in causes automerge-prosemirror to crash during initialization:
Uncaught Error: Match cannot be null
set currentMatch traversal.ts:619
newBlock traversal.ts:650
traverseSpans traversal.ts:597
pmDocFromSpans traversal.ts:64
init index.ts:84
<anonymous> main.ts:40
It crashes in a similar way--the top four frames are identical--while-you-edit if two copies of the page are open pointing at the same document.
The actual substantial change to repro is to copy src/schema.ts and modify the bit about horizontal rules to read
https://github.com/kythyria/automerge-prosemirror-issue-badblocks is a vanilla JS example sufficient to reproduce, npm run dev, open the URL, try inserting a <hr> using the toolbar (could probably paste one too), observe that reloading the page fails, as does opening it in a second tab.
The text was updated successfully, but these errors were encountered:
Attempting to modify the schema in
src/schema.ts
to add support for<hr>
looks initially like it will work, but instead attempting to load a document with one in causes automerge-prosemirror to crash during initialization:It crashes in a similar way--the top four frames are identical--while-you-edit if two copies of the page are open pointing at the same document.
The actual substantial change to repro is to copy
src/schema.ts
and modify the bit about horizontal rules to readthen pass the resulting
schemaAdapter
toinit()
.https://github.com/kythyria/automerge-prosemirror-issue-badblocks is a vanilla JS example sufficient to reproduce,
npm run dev
, open the URL, try inserting a<hr>
using the toolbar (could probably paste one too), observe that reloading the page fails, as does opening it in a second tab.The text was updated successfully, but these errors were encountered: