Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Does not work with Next.js #737

Open
18601673727 opened this issue Apr 14, 2024 · 1 comment
Open

Does not work with Next.js #737

18601673727 opened this issue Apr 14, 2024 · 1 comment

Comments

@18601673727
Copy link

18601673727 commented Apr 14, 2024

"use client"

import { PlainTextKit } from "@doist/typist"

const TypistEditor = dynamic(() => import("@doist/typist").then((mod) => mod.TypistEditor), {
  ssr: false,
})

// ...Later in render()

<TypistEditor placeholder="A full rich-text editor, be creative…" content={value} extensions={[PlainTextKit]} />

result in error:

Unhandled Runtime Error
TypeError: this.docView is null
@mwolf1989
Copy link

Same for me.

Created a use client TypistEditor Component, try to use it in a page but get this error:

TypeError: Cannot read properties of null (reading 'updateOuterDeco')

Call Stack
EditorView.updateStateInner
node_modules/prosemirror-view/dist/index.js (5305:1)
EditorView.update
node_modules/prosemirror-view/dist/index.js (5234:1)
EditorView.setProps
node_modules/prosemirror-view/dist/index.js (5248:1)
Editor.createNodeViews
node_modules/@tiptap/core/dist/index.js (3894:1)
PureEditorContent.init
node_modules/@tiptap/react/dist/index.js (52:1)
PureEditorContent.componentDidMount
node_modules/@tiptap/react/dist/index.js (35:1)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants