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

Bug: No Bare URLs Breakages in Code Block and Smart Typography #469

Closed
1 task done
charlesroper opened this issue Nov 2, 2022 · 3 comments · Fixed by #471
Closed
1 task done

Bug: No Bare URLs Breakages in Code Block and Smart Typography #469

charlesroper opened this issue Nov 2, 2022 · 3 comments · Fixed by #471
Labels
bug Something isn't working

Comments

@charlesroper
Copy link

Describe the Bug

The No Bare URLs rule produces a few unexpected results.

  1. When using the Smart Typography extension, quoted URLs get converted. E.g.,

    • ‘https://google.com’‘<https://google.com’>
    • “https://google.com”“<https://google.com”>
  2. URLs within backticks containing text other than just the URL. E.g.,

    • `http --headers --follow --all https://google.com``http --headers --follow --all <https://google.com>`

2022-11-02_01

2022-11-02_02

How to Reproduce

  1. Install Smart Typography extension and use linter on text with curly quotes and No Bare URLs turned on.

  2. Has nothing to do with Smart Typography - just run the linter on a backticked string containing a some text + a url.

Device

  • Desktop

Mobile not tested

@charlesroper charlesroper added the bug Something isn't working label Nov 2, 2022
@pjkaufman
Copy link
Collaborator

Thanks for reporting this. I am pretty sure that number 1 is already listed as something that can happen in the linter rule documentation, but I could be wrong. I can see about just ignoring code blocks altogether.

As for smart typography, there currently are no checks for it since it breaks a lot of things to use smart typography. But I can add some checks to the logic for it.

@pjkaufman pjkaufman changed the title Bug: No Bare URLs breakages Bug: No Bare URLs Breakages in Code Block and Smart Typography Nov 2, 2022
@pjkaufman
Copy link
Collaborator

I think I have a fix for this. I am testing it now.

@pjkaufman
Copy link
Collaborator

I have a fix and will push it up. Note that it will likely go out with the next release unless I get a couple more bugs fixed. If so, I will try to do a bug fix release tomorrow or Friday.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Archived in project
2 participants