-
Notifications
You must be signed in to change notification settings - Fork 57
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
handle nbsp (nonbreaking space) in headings #141
Comments
@zebapy, I'm on board with this. It's definitely an edge-case, but a good-enough solution seems pretty low-overhead and straightforward. As for the approach, he looks nice but I want to keep anchorjs dependency-free. I like the simplicity of the textarea approach. It shouldn't be hard to add it at the beginning of our urlify function, and add a test for it. The biggest downside of this change is that it would require at least a minor (if not major) version bump, since we could be potentially changing link locations for existing users. I'm ok with that, but if I'm doing a major version bump, I want to include #109 in it as well. Feel free to submit a PR if you want to take a pass at this. Otherwise, I'll get to it eventually. |
I'm also encountering curly quotes and degree icons not being replaced with nothing. |
@zebapy, the quotes and degree icons are a part of the decision to support UTF-8 characters (except for a small set of non-safe characters). I had originally stripped out these kinds of characters, but I changed the approach in order to better support international characters. For more background on that decision, see: #41 The |
Our site uses a plugin to prevent widows by adding a
between the last 2 words of most elements (h1, p, etc).When using anchorjs, this is causing some headings to come out as
Everything is functional but the anchor link suffers in readability after.
The text was updated successfully, but these errors were encountered: