-
-
Notifications
You must be signed in to change notification settings - Fork 199
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
Ignore <a href="#"> when checking internal links #118
Comments
You need to set the |
Ah, thanks, wonder how I missed this when looking at the help ;-) |
@gjtorikian did ignore some protocols by default like in the README
It probably is a safe default, but if there is no way to opt out of the built in ignore it might hide bad links for other projects that don't use the "#" links for JS actions |
Yep, good point. As long as I can ignore it with the |
@nschonni Thank you for pointing to the |
I think that this bug should be reopen, Jekyll should ignore this one by default, because as already pointed, that's valid, and also quite common. Default settings should be friendly. |
You mean Proofer, right? |
I think |
It seems in version 3.0.5 there is no option
|
After I lot of search, I figure I have to write RegExps like |
with --ignore-url option internal link(#) must be the primary value gjtorikian/html-proofer/issues/118
I'm just writing a note here to clarify since I see other people are linking to this page. To set the record straight:
A lot of people do it, but it's wrong. Usually the correct solution is to have Exception: if you have something like Gmail where the fragment is |
While true that empty anchor fragment
https://html.spec.whatwg.org/multipage/browsing-the-web.html#scroll-to-the-fragment-identifier It could be used this way for "Back to Top" links shown at the bottom of a page, for example. See also #421, which added explicit support for |
There may be some confusion in WHATWG as to what is a null fragment and what is an empty string fragment. But here is the authoritative text:
And also, for the relative URL "#", here is the respective line:
And then as you note:
Therefore, a link to "#" is always valid. Thank you, I stand corrected. Issue is valid. |
Arguably a bug in HTMLProofer, ref: gjtorikian/html-proofer#118
Arguably a bug in HTMLProofer, ref: gjtorikian/html-proofer#118
For those ended up here via search, passing |
Closing this out as an old issue. I'm working on the next major upgrade for HTMLProofer and guaranteed that |
Arguably a bug in HTMLProofer, ref: gjtorikian/html-proofer#118
Using such anchors is quite a common practice (e.g. by Bootstrap Dropdowns) and generates the following error:
I think they shouldn't trigger an error as they are just used as a placeholder and not for linking to a specific part of the document.
The text was updated successfully, but these errors were encountered: