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

Allow access to the range for a link's destination #109

Open
d-ronnqvist opened this issue Mar 8, 2023 · 0 comments
Open

Allow access to the range for a link's destination #109

d-ronnqvist opened this issue Mar 8, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@d-ronnqvist
Copy link
Contributor

There are a few different ways to write links in markdown:

[link text](https://example.com)

<https://example.com>

[link text][1]
  
[1]: https://example.com

The Link type provides access to the range and destination but it doesn't provide access to the range of the destination.

A client can workaround this limitation in the first two cases where the destination exist within the content of the range but in the third example the range only covers this content [link text][1].

Swift-DocC has a use-case where it verifies links in the documentation content and raises diagnostics about unresolvable links. In these diagnostics it's helpful to have access to the range of the link destination to be able to make accurate suggestions on how to correct the link.

@d-ronnqvist d-ronnqvist added the enhancement New feature or request label Mar 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant