We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hello, I am looking for help to get textlint to verify my website's relative links within my HUGO website.
textlint
Any help would be greatly appreciated!
Thanks ~
example.com/en/content
baseURL
/en/
baseURI
"baseURI": "https://example.com/en/",
https://example.com/
https://example.com/en/blog1
https://example.com/blog1
.textlintrc
{ "rules": { "prh": { "rulePaths": ["../../rules/global/prh.yml"] }, "@textlint-rule/require-header-id": true, "@textlint-rule/no-invalid-control-character": true, "no-dead-link": { "checkRelative": true, "baseURI": "https://example.com/en/", "checkRelative": false, "baseURI": null, "ignore": [ "https://example.com/**", "https://api.example.com/**", "https://www.linkedin.com/**", "https://github.com/**" ], "preferGET": [], "ignoreRedirects": true, "retry": 3, "userAgent": "textlint-rule-no-dead-link/1.0", "maxRetryTime": 10 } }, "filters": { "allowlist": { "allow": [ "product: example" ], "allowlistConfigPaths": [ "../../rules/allow.yml" ] }, "comments": true } }
Relative links and i18n · Issue #146
The text was updated successfully, but these errors were encountered:
baseURI + path is joined by url.resolve(from, to)
textlint-rule-no-dead-link/src/no-dead-link.js
Line 272 in e1e0cdd
Probably, your path is written as /blog1. As a result, url.resolve("https://example.com/en/", "/blog1") to be 'https://example.com/blog1'.
path
/blog1
url.resolve("https://example.com/en/", "/blog1")
'https://example.com/blog1'
> url.resolve("https://example.com/en/", "/blog1") 'https://example.com/blog1' > url.resolve("https://example.com/en/", "blog1") 'https://example.com/en/blog1'
We need to found suitable option/behavior for #146
📝 Some options:
Sorry, something went wrong.
No branches or pull requests
Hello, I am looking for help to get
textlint
to verify my website's relative links within my HUGO website.Any help would be greatly appreciated!
Thanks ~
Goal
example.com/en/content
)textlint
to verify relative links with thebaseURL
with the language subdirectory. (Specifically English's/en/
)Problem
baseURI
, but it seems to be ignored."baseURI": "https://example.com/en/",
textlint
acts as if ourbaseURI
is onlyhttps://example.com/
.https://example.com/en/blog1
, it testshttps://example.com/blog1
and returns 404.Our configurations in
.textlintrc
Related Issue
Relative links and i18n · Issue #146
The text was updated successfully, but these errors were encountered: