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
Links on declaration titles are broken for re-exports from other packages #3504
Labels
Comments
hdgarrood
added a commit
that referenced
this issue
Jan 7, 2019
The concept of the current module is unnecessary (we aren't using it anywhere either in the compiler or in Pursuit) as well as potentially confusing; for example, what is the 'current module' when we are rendering re-exported declarations? Additionally, since the information is not used, it would be easy for it to become incorrect without anyone noticing. This commit refactors the Docs related code, removing the concept of the current module. Specifically, the following have been removed: - the SameModule constructor from the LinkLocation data type; wherever we previously would have used that, we can now use the LocalModule constructor, which encodes precisely the same information. - the 'current module' field from the constructors LocalModule and DepsModule of the data type LinkLocation, which was unused. - the 'currentModuleName' field of the HtmlRenderContext data type, which was also unused. I came across this refactoring opportunity while looking into #3504.
hdgarrood
added a commit
that referenced
this issue
Jan 7, 2019
The concept of the current module is unnecessary (we aren't using it anywhere either in the compiler or in Pursuit) as well as potentially confusing; for example, what is the 'current module' when we are rendering re-exported declarations? Additionally, since the information is not used, it would be easy for it to become incorrect without anyone noticing. This commit refactors the Docs related code, removing the concept of the current module. Specifically, the following have been removed: - the SameModule constructor from the LinkLocation data type; wherever we previously would have used that, we can now use the LocalModule constructor, which encodes precisely the same information. - the 'current module' field from the constructors LocalModule and DepsModule of the data type LinkLocation, which was unused. - the 'currentModuleName' field of the HtmlRenderContext data type, which was also unused. I came across this refactoring opportunity while looking into #3504.
dariooddenino
pushed a commit
to dariooddenino/purescript
that referenced
this issue
Jan 18, 2019
The concept of the current module is unnecessary (we aren't using it anywhere either in the compiler or in Pursuit) as well as potentially confusing; for example, what is the 'current module' when we are rendering re-exported declarations? Additionally, since the information is not used, it would be easy for it to become incorrect without anyone noticing. This commit refactors the Docs related code, removing the concept of the current module. Specifically, the following have been removed: - the SameModule constructor from the LinkLocation data type; wherever we previously would have used that, we can now use the LocalModule constructor, which encodes precisely the same information. - the 'current module' field from the constructors LocalModule and DepsModule of the data type LinkLocation, which was unused. - the 'currentModuleName' field of the HtmlRenderContext data type, which was also unused. I came across this refactoring opportunity while looking into purescript#3504.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
For example, the link I'm hovering over in this screenshot is broken, because it assumes that
Cons
exists in the current package. These docs are from version 3.0.0 of typelevel-prelude.I'd like to consider solving this by removing links on declaration titles entirely, and just making them bold - this is what Hackage does. I think this would be a better UI, as it would better distinguish the name being declared from everything else. This could be particularly helpful for certain declarations such as type classes, for instance, since it's not always obvious which is the superclass and which is the class currently being declared (if you're not sufficiently familiar with the syntax). The links are sort of pointless anyway, as they would put you right where you already are; if you want a link to copy which you can send to other people, that's what the hash (#) to the left of the declaration is for.
The text was updated successfully, but these errors were encountered: