fix: streamline html package generation functions to work as expected #5257
+10
−50
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Changes Overview
This PR removes logic that was specific to the
@tiptap/html
package and didn't work the same way the coregenerateHTML
andgenerateJSON
functions work. This caused issues with a few extensions (for example the Youtube extension not being able to be generated back to HTML from JSON, see #4089)I kept the original HTML
getJSON
andgetHTML
functions to not break existing code for users but maybe we should add a deprecation message to it?Implementation Approach
I removed the logic of the functions of the html package and just used a reference to the core packages util functions.
Testing Done
I tried running JSON and HTML generation steps before and after and checked if unexpected things were happening or the output was false.
Verification Steps
Additional Notes
Checklist
feat: Implement new feature
orchore(deps): Update dependencies
)Related Issues