I have prosemirror setup with collaboration but have encountered an exception raised in Chrome that doesn’t occur in Firefox:
setSelection (prosemirror-view/src/viewdesc.js:366): Uncaught (in promise) DOMException: Failed to execute 'extend' on 'Selection': This Selection object doesn't have any Ranges.
It’s triggered when I have two collaborators editing the same document and one of them deletes all of the text in the document. If the other browser is Chrome the exception is raised. If the other browser is Firefox the exception is not.
I found a similar bug in draft-js: https://github.com/facebook/draft-js/issues/1188
Which they tracked to this change in Chrome: https://bugs.chromium.org/p/chromium/issues/detail?id=690240
It looks like the spec requires an exception when calling
.extend() with an empty range. I assume Firefox doesn’t implement the spec correctly.