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

Cyrillic "й" is replaced by сyrillic "и" in the anchor link #3156

Open
v1talii-dev opened this issue Jul 21, 2023 · 3 comments
Open

Cyrillic "й" is replaced by сyrillic "и" in the anchor link #3156

v1talii-dev opened this issue Jul 21, 2023 · 3 comments

Comments

@v1talii-dev
Copy link

v1talii-dev commented Jul 21, 2023

Bug report

Enviroment

Steps to reproduce

  • Add a heading with lowercase cyrillic letter "й" ## Списки пользователей
  • Check generated anchor link. The result should be like this: <h2 id="списки-пользователеи"><a href="#списки-пользователеи" class="header-anchor">#</a> Списки пользователей</h2>

What is expected?

<h2 id="списки-пользователей"><a href="#списки-пользователей" class="header-anchor">#</a> Списки пользователей</h2>

What is actually happening?

Cyrillic "й" is replaced by cyrilliс "и" in the anchor link.

Other relevant information

@v1talii-dev
Copy link
Author

@larionov, what do you think this might be related to?

@larionov
Copy link
Contributor

larionov commented Jul 28, 2023

@v1talii-dev It specifically removes all accents on characters, so it is expected. If we want to keep "й" we would have to make individual custom implementations for different languages. https://github.com/vuejs/vuepress/blob/master/packages/%40vuepress/shared-utils/src/slugify.ts#L12-L13

@v1talii-dev
Copy link
Author

@larionov How can this behavior be redefined not only for the first heading level, but also for the second, third?

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

2 participants