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

FR: Have shortcut reference links to go through reference resolution #818

Open
rickeylev opened this issue Oct 18, 2023 · 1 comment
Open

Comments

@rickeylev
Copy link

It'd be very convenient if shortcut reference lines were able to perform reference resolution.

For reference, a shortcut reference link is this:

[foo]
[`foo`]

See https://spec.commonmark.org/0.30/#shortcut-reference-link

As far as I can tell, however, they don't do any reference lookups. I'm not sure what resolves them, but I'm been unable to get them to participate in the sort of reference lookup that e.g. [foo](bar) (or the role/autolink equivs) performs. They seem to only look in the current page/render context for a label. This also means, if you have many docs, each page must copy/paste the same [foo]: destination content somewhere on its page (include directives don't work; however they work, labels in the included page aren't available to the includer page).

The reason this is convenient is you can then write docs using very familiar markdown syntax:

Args:
  foo: [`list`] of [`int`] bla bla

The alternatives are fairly non-trivial or quite verbose. Autolink syntax is unfamiliar and not very intuitive (what domain? type? etc). A custom role requires a sphinx extension of some sort (which are not well documented). The link-with-ref syntax, quickly becomes unwieldy: [list](list) of [int](int) (throw a dict or union in there and its a lot of repetition).

This issue seems somewhat related: #193

@welcome
Copy link

welcome bot commented Oct 18, 2023

Thanks for opening your first issue here! Engagement like this is essential for open source projects! 🤗

If you haven't done so already, check out EBP's Code of Conduct. Also, please try to follow the issue template as it helps other community members to contribute more effectively.

If your issue is a feature request, others may react to it, to raise its prominence (see Feature Voting).

Welcome to the EBP community! 🎉

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant