Skip to content

Conversation

basile-henry
Copy link

The main thing this PR does is add links for types that are defined in dependencies.

The motivation is to be able to quickly navigate to related documentation that is directly relevant to a package's docs. It also helps to disambiguate what types a package uses, which is particularly useful for heavily overloaded type names such as Color (I can never figure out which one is intended 😅).

In order to do this we have to find out which version of a dependency to link to. While it might be tempting to link to the latest version, it could lead to broken links if the type is removed/changed in the latest version of the dependency. As such we instead link to the most recent version that matches the constraint associated with the dependency. In this PR I am calling this a ResolvedDep.

This PR does 2 extra things:

  • In the about section, link to the version from the ResolvedDep instead of latest if the dependency could be resolved.
  • Link to type aliases and not just type unions. I now realise this was also done in Add links to type aliases #353

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

Successfully merging this pull request may close these issues.

1 participant