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

Would be nice to post process the doc block for links #142

Open
chenglou opened this issue Apr 26, 2021 · 2 comments
Open

Would be nice to post process the doc block for links #142

chenglou opened this issue Apr 26, 2021 · 2 comments
Labels
enhancement New feature or request

Comments

@chenglou
Copy link
Member

Low pri.

For a doc block such as:

@ocaml.doc("
  The top level provides some generic sort related utilities.
  It also has two specialized inner modules
  [`Belt.SortArray.Int`](...) and [`Belt.SortArray.String`](...)
")

it'd be nice to postprocess those links so that they're clickable. The IDE supports that. Caveat: doesn't support jumping to a line, so most of the links will be useless for now.

@zth
Copy link
Collaborator

zth commented Apr 27, 2021

It was a while since I dug into the specifics, but for the VSCode part I think it might be possible to link to a command from the extension. If so, one could imagining having a command that opens a file and scrolls to a certain position, but programmatically. I've done similar things before, so I'll have a look around if that's possible and report back here.

@zth
Copy link
Collaborator

zth commented Apr 27, 2021

Yes, this seems possible: https://code.visualstudio.com/api/extension-guides/command#command-uris

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

3 participants