Closed volarname closed 2 days ago
And unfortunately, reverting to 2.6.6 has its own issues, due to these lines in the vue-3 package.json (also starter-kit and pm)... because they haven't locked down the specific versions, it'll use the latest minor version, which is 2.7.2. What I ended up having to do is adding the overrides in my package.json, so it looks like this:
"overrides": {
"@incutonez/ui": {
"@tiptap/vue-3": {
"@tiptap/core": "2.6.6",
"@tiptap/extension-bubble-menu": "2.6.6",
"@tiptap/extension-floating-menu": "2.6.6",
"@tiptap/pm": "2.6.6"
},
"@tiptap/pm": {
"@tiptap/core": "2.6.6"
},
"@tiptap/starter-kit": {
"@tiptap/core": "2.6.6",
"@tiptap/pm": "2.6.6"
}
}
}
In my case, I'm using workspaces, so if you're using workspaces, rename the @incutonez/ui
to whatever workspace you're using TipTap in. If you're not using workspaces, simply remove the wrapping @incutonez/ui
object.
try defineProps(nodeViewProps)
try
defineProps(nodeViewProps)
thx, but not working, then there are differen ts errors it worked everything perfectly but after latest hotfix there are several ts issues with tiptap, also with plugin decorations
this should be part of minor release at least, not hotfix, when they introduced breaking changes
The types were changed in 2.7 which is a minor.
The types were changed in 2.7 which is a minor.
ok but its now broken
I'd be willing to take a PR for this. But I think all that is happening is that you cannot use
import { NodeViewContent, NodeViewWrapper, type NodeViewProps as TiptapNodeViewProps } from '@tiptap/vue-3'
interface Props extends TiptapNodeViewProps {}
const props = defineProps<Props>()
it has to be
import { NodeViewContent, NodeViewWrapper, type NodeViewProps as TiptapNodeViewProps } from '@tiptap/vue-3'
type Props = TiptapNodeViewProps
const props = defineProps<Props>()
because the type went from being an interface to a type now: https://github.com/ueberdosis/tiptap/blob/9e18d243e048ad9c09e5da1cb65eeddff141cc0e/packages/core/src/types.ts#L217
@nperez0111 thank you, just wating for hotfix release
This has already been released with 2.7.3, but now we already have 2.7.4
Affected Packages
core, vue-3
Version(s)
2.7.0,2.7.1,2.7.2
Bug Description
this worked before, also it was on documentation before, now it doesn't
if this is not bug, please provide TS example how to properly type props in node view renderer in vue 3
error log from vue sfc compiler:
Browser Used
Chrome
Code Example URL
No response
Expected Behavior
no compiler error as before
Additional Context (Optional)
No response
Dependency Updates