-
Notifications
You must be signed in to change notification settings - Fork 16
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
Add function to apply conversion rules to generated markdown links #55
Conversation
Please note that these test failures should be fixed once PR #52 has been accepted and merged (both into main and my branch). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! Just had one question.
link_str = text_str.strip() | ||
|
||
#Next, make sure all text is lowercase: | ||
link_str = link_str.lower() |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this check necessary? It appears as if the old links with capital letters still work in the web view, but maybe there's another markdown reader where it doesn't work?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That's a good question! After doing some experimentation it looks like at least my web browser (Chrome) is able to use a URL with uppercase text correctly, but I think "under the hood" the actual link is still all lowercase. You can see this if you go to to one of the section heads in the markdown document itself and then click on the the little chain symbol that pops up next to it.
So, I am happy to remove this text conversion if that is preferred by you or others, but I personally think keeping everything lowercase will be the safest option in the long run. Of course please let me know if you disagree!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's fine to leave the check in, I was just curious if it was causing issues.
@mkavulich I removed the "needs discussion" label on this PR because I think you meant to add it to PR #56 instead based off of my memory of Monday's framework meeting discussions. However, if I am wrong here then feel free to add the label back. Thanks! |
@nusbaume Yes, you're right I applied the label to the wrong PR. Thanks for fixing that! |
This PR adds a function to apply header text conversion rules when generating internal markdown document links.
Fixes #54