vuejs / vuepress

📝 Minimalistic Vue-powered static site generator
https://vuepress.vuejs.org
MIT License
22.5k stars 4.77k forks source link

"_" is removed in sidebar and search box from some header containing underscore #1208

Open nelson6e65 opened 5 years ago

nelson6e65 commented 5 years ago

Bug report

When I have a header (##) that contains an underscore (_), the title in sidebar misses the _ character. Also, in the search box result title is displayed without _ and also is exclude from results if I type the title containing _.

The weird thing is that this does not happen in all cases:

Screenshot-1

NML_VERSION, in this case, works as expected.

PD: The link reference is ok, like in the screenshot that works fine (https://nelson6e65.github.io/php_nml/api/constants.html#nml-gettext-domain)

Version

Steps to reproduce

What is expected?

What is actually happening?

_ is being hidden from sidebar and search in some cases

Other relevant information

nelson6e65 commented 5 years ago

If I escape _ in the title, they display well:

- ## NML_GETTEXT_DOMAIN
+ ## NML\_GETTEXT\_DOMAIN

Maybe is misinterpreted as markdown cursive in sidebar and search indexes?

pajachiet commented 4 years ago

Maybe a duplicate of https://github.com/vuejs/vuepress/issues/544 ?