Skip to content
This repository has been archived by the owner on Nov 7, 2022. It is now read-only.

Create a new ReactRenderer for @tiptap ReactNodeView #378

Closed
Darmody opened this issue Jul 15, 2022 · 4 comments · Fixed by #429
Closed

Create a new ReactRenderer for @tiptap ReactNodeView #378

Darmody opened this issue Jul 15, 2022 · 4 comments · Fixed by #429
Assignees
Labels
tech-debt We should rework on this

Comments

@Darmody
Copy link
Contributor

Darmody commented Jul 15, 2022

Is your feature request related to a problem?

After upgrading to React 18, the @tiptap react-renderer encounters an async render problem ueberdosis/tiptap#2985

Describe the solution you'd like

To make react renderer work well with Prosemirror, we need to build a new ReactNodeView renderer instead of @tiptap's one.

Describe alternatives you've considered

Fixed the problem by patching the @tiptap package but is not perfect. As a consequence of the implementation of the @tiptap react-renderer, react will through an annoying warning about flushSync usage.

Additional context

Making react 18's new render mode work with Prosemirror correctly may be a siginficant part of this refactor.

@Darmody Darmody added the tech-debt We should rework on this label Jul 15, 2022
@Darmody Darmody self-assigned this Jul 15, 2022
@Darmody
Copy link
Contributor Author

Darmody commented Jul 15, 2022

ref: https://github.com/remirror/remirror Remirror has upgraded to react 18 already and looks to work well.

@Darmody
Copy link
Contributor Author

Darmody commented Jul 19, 2022

@Darmody
Copy link
Contributor Author

Darmody commented Jul 19, 2022

cc @aligo @clszzyh @stackia @melchior-voidwolf

packages/editor is about to rename to packages/legacy_editor

@Darmody
Copy link
Contributor Author

Darmody commented Jul 19, 2022

After comparing remirror and tiptap, I think the problem is that tiptap still uses react legacy class component API.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
tech-debt We should rework on this
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant