@prosekit/react 0.3.21 → 0.3.23
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/dist/prosekit-react.js +5 -6
- package/package.json +6 -6
package/dist/prosekit-react.js
CHANGED
@@ -18,11 +18,10 @@ import {
|
|
18
18
|
} from "@prosemirror-adapter/react";
|
19
19
|
import { createElement, useMemo as useMemo2 } from "react";
|
20
20
|
|
21
|
-
// src/hooks/use-extension.ts
|
22
|
-
import "@prosekit/core";
|
23
|
-
|
24
21
|
// src/hooks/use-editor-extension.ts
|
25
|
-
import {
|
22
|
+
import {
|
23
|
+
EditorNotFoundError
|
24
|
+
} from "@prosekit/core";
|
26
25
|
import { useEffect } from "react";
|
27
26
|
function useEditorExtension(editor, extension) {
|
28
27
|
if (!editor) {
|
@@ -134,10 +133,10 @@ function useEditor(options) {
|
|
134
133
|
const forceUpdate = useForceUpdate();
|
135
134
|
useEffect2(() => {
|
136
135
|
if (update) {
|
137
|
-
const extension = union(
|
136
|
+
const extension = union(
|
138
137
|
defineMountHandler(forceUpdate),
|
139
138
|
defineUpdateHandler(forceUpdate)
|
140
|
-
|
139
|
+
);
|
141
140
|
return editor.use(extension);
|
142
141
|
}
|
143
142
|
}, [editor, update, forceUpdate]);
|
package/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@prosekit/react",
|
3
3
|
"type": "module",
|
4
|
-
"version": "0.3.
|
4
|
+
"version": "0.3.23",
|
5
5
|
"private": false,
|
6
6
|
"author": {
|
7
7
|
"name": "ocavue",
|
@@ -67,8 +67,8 @@
|
|
67
67
|
"dependencies": {
|
68
68
|
"@prosemirror-adapter/react": "^0.2.6",
|
69
69
|
"react-merge-refs": "^2.1.1",
|
70
|
-
"@prosekit/core": "^0.7.
|
71
|
-
"@prosekit/web": "^0.3.
|
70
|
+
"@prosekit/core": "^0.7.9",
|
71
|
+
"@prosekit/web": "^0.3.11",
|
72
72
|
"@prosekit/pm": "^0.1.8"
|
73
73
|
},
|
74
74
|
"peerDependencies": {
|
@@ -88,9 +88,9 @@
|
|
88
88
|
"@types/react-dom": "^18.3.0",
|
89
89
|
"react": "^18.3.1",
|
90
90
|
"react-dom": "^18.3.1",
|
91
|
-
"tsup": "^8.2.
|
92
|
-
"typescript": "^5.5.
|
93
|
-
"vitest": "^2.0.
|
91
|
+
"tsup": "^8.2.4",
|
92
|
+
"typescript": "^5.5.4",
|
93
|
+
"vitest": "^2.0.5",
|
94
94
|
"@prosekit/dev": "0.0.0"
|
95
95
|
},
|
96
96
|
"scripts": {
|