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

Broken autolink when two or more _ (underscores) used in the title #142

Closed
szymonpk opened this issue Jan 3, 2020 · 5 comments
Closed

Comments

@szymonpk
Copy link

szymonpk commented Jan 3, 2020

First of all, thanks for the awesome plugin! I tried to dig into this myself, but I couldn't find an easy solution. Autolinking generates the wrong TOC when multiple underscores (_) are used.

How can the issue be reproduced

# One_title

# An_other_title

What was expected

<!-- MarkdownTOC autolink="true" -->

- [One_title](#one_title)
- [An_other_title](#an_other_title)

<!-- /MarkdownTOC -->

What actually occurred

<!-- MarkdownTOC autolink="true" -->

- [One_title](#one_title)
- [An_other_title](#anothertitle)

<!-- /MarkdownTOC -->

Notice missing _ from second title.

What was the version of the involved component

MarkdownTOC v3.0.4 and Sublime 3.2.2 build 3211

@naokazuterada
Copy link
Owner

@szymonpk
Hi, thank you for reporting.
I also confirmed that there was a bug. Sorry! I will fix it in a week.

@naokazuterada
Copy link
Owner

@szymonpk

Sorry for late reaction. Your problem will be fixed in 3.0.5. Please check it!

@szymonpk
Copy link
Author

szymonpk commented Jan 14, 2020

@naokazuterada thank you very much! My case is fixed.

Although, I found another one :/

<!-- MarkdownTOC autolink="true" -->

- [t_h_i_s](#thi_s)

<!-- /MarkdownTOC -->

# t_h_i_s

Looks like single characters are the issue. Should I create another issue?

@naokazuterada
Copy link
Owner

@szymonpk
Hi, thank you for your detailed report!
I released fix release at 4.0.0.
Please check "Upgrade Guide" on the release note and make sure your settings updated.

@szymonpk
Copy link
Author

Thank you very much!

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