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

Provide a way to plugin to know added and deleted DOM elements for blocks when rewrite with Content Model #2860

Open
JiuqingSong opened this issue Nov 4, 2024 · 0 comments

Comments

@JiuqingSong
Copy link
Collaborator

We can find a way to pass the added and deleted DOM element for blocks when rewrite with Content Model.

For example, in editor we have:

1
2
3

And in Content Model we have:
Paragraph1: cachedElement = div 1
Paragraph2: cachedElement = undefined
Paragraph3: cachedElement = div 3

When rewrite, div1 and div3 will not be changed, we need to delete div2 and create a new DIV. After that, we can pass the old div2 and new DIV to plugins so they can do necessary actions if they have some DOM elements cached in the plugins.

JiuqingSong added a commit that referenced this issue Nov 14, 2024
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

1 participant