@slate-yjs/core
Advanced tools
Comparing version 0.2.5 to 0.2.6
# @slate-yjs/core | ||
## 0.2.6 | ||
### Patch Changes | ||
- [#352](https://github.com/BitPhinix/slate-yjs/pull/352) [`3e172a6`](https://github.com/BitPhinix/slate-yjs/commit/3e172a63f6d0a298da26975cb2b6831a02f81f2b) Thanks [@BitPhinix](https://github.com/BitPhinix)! - Throw error in non-static connect call if editor is already connected | ||
## 0.2.5 | ||
@@ -4,0 +10,0 @@ |
@@ -866,5 +866,2 @@ var __defProp = Object.defineProperty; | ||
connect(editor) { | ||
if (YjsEditor.connected(editor)) { | ||
throw new Error("already connected"); | ||
} | ||
editor.connect(); | ||
@@ -946,2 +943,5 @@ }, | ||
e.connect = () => { | ||
if (YjsEditor.connected(e)) { | ||
throw new Error("already connected"); | ||
} | ||
sharedRoot.observeDeep(handleYEvents); | ||
@@ -948,0 +948,0 @@ const content = yTextToSlateElement(e.sharedRoot); |
{ | ||
"name": "@slate-yjs/core", | ||
"sideEffects": false, | ||
"version": "0.2.5", | ||
"version": "0.2.6", | ||
"description": "Yjs binding for Slate.", | ||
@@ -6,0 +6,0 @@ "keywords": [ |
@@ -87,6 +87,2 @@ import { BaseEditor, Descendant, Editor, Operation, Point } from 'slate'; | ||
connect(editor: YjsEditor): void { | ||
if (YjsEditor.connected(editor)) { | ||
throw new Error('already connected'); | ||
} | ||
editor.connect(); | ||
@@ -210,2 +206,6 @@ }, | ||
e.connect = () => { | ||
if (YjsEditor.connected(e)) { | ||
throw new Error('already connected'); | ||
} | ||
sharedRoot.observeDeep(handleYEvents); | ||
@@ -212,0 +212,0 @@ const content = yTextToSlateElement(e.sharedRoot); |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
1754389