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

Always include text while using to_h #21

Merged
merged 1 commit into from
Jul 18, 2024
Merged

Conversation

chadwilken
Copy link
Collaborator

Description

If the text attribute is nil then the call to compact_blank removes the text key from the hash. It turns out that makes the TipTap Document invalid when parsed by the JS library.

Reason/Reference

We should always include text, even if an empty string.

@chadwilken chadwilken requested a review from a team July 18, 2024 20:35
@chadwilken chadwilken merged commit b102d70 into master Jul 18, 2024
3 checks passed
@chadwilken chadwilken deleted the fix/always-include-text branch July 18, 2024 21:04
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

Successfully merging this pull request may close these issues.

3 participants