@brett_lamy/docstream-editor 1.0.0 → 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@brett_lamy/docstream-editor",
3
- "version": "1.0.0",
3
+ "version": "1.0.1",
4
4
  "description": "TipTap editor for Docstream GitBook-style markdown documents.",
5
5
  "type": "module",
6
6
  "scripts": {
@@ -295,7 +295,8 @@ export function GitbookEditor({
295
295
  }, [editor, onEditorReady])
296
296
 
297
297
  useEffect(() => {
298
- if (!editor || !controlled) return
298
+ // StrictMode (and <Activity>) re-run effects against an editor useEditor has already destroyed.
299
+ if (!editor || editor.isDestroyed || !controlled) return
299
300
  if (markdown === lastEmitted.current) return
300
301
  lastEmitted.current = markdown as string
301
302
  const doc = parseMarkdown(markdown as string)