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

Preserve   (Non-breaking whitespace) #168

Closed
ustych opened this issue Jan 18, 2019 · 5 comments
Closed

Preserve   (Non-breaking whitespace) #168

ustych opened this issue Jan 18, 2019 · 5 comments

Comments

@ustych
Copy link

ustych commented Jan 18, 2019

I have a problem with outputting html after setContent(). When i add non-breaking space with html entity (nbsp;) Editor replaces all non-breaking spaces to default spaces. I need to preserve that special chars. What can i do in this situation?

@litvinchuk
Copy link

Same problem
I think it's referring to https://prosemirror.net/docs/ref/#model.ParseOptions.preserveWhitespace
But there is no method to pass this option

@WMP33
Copy link

WMP33 commented Mar 5, 2019

Same Problem.
To have the option added to setContent would be great

@mayacoda
Copy link
Contributor

mayacoda commented Apr 5, 2019

Same issue when passing content to the Editor constructor. I'll submit a PR to add passing ParserOptions to fix this issue.

@philippkuehn
Copy link
Contributor

fixed with #254

@zalbastakiNetsells
Copy link

zalbastakiNetsells commented Jul 12, 2019

Note: the option is parseOptions and not parserOptions 😛had to look into the diff to figure that one out

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

6 participants