x/pkgsite: add import / imported by counts #37912
Labels
FeatureRequest
Issues asking for a new feature that does not need a proposal.
FrozenDueToAge
NeedsInvestigation
Someone must examine and confirm this is a valid issue and not a duplicate of an existing one.
pkgsite
UX
Issues that involve UXD/UXR input
Milestone
What is the URL of the page with the issue?
https://pkg.go.dev/github.com/CloudyKit/jet
What is your user agent?
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_12_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/80.0.3987.122 Safari/537.36
Screenshot
What did you do?
Visited the page.
What did you expect to see?
What did you see instead?
From the main Doc page, you can't see how many imports/imported-by the package has.
One of the useful things about the Godoc pages was at the bottom you could get an instant gauge of how popular or in-use the package was based on the "imported by" count. You could also get an instant gauge of how-many-dependencies-am-i-committing-to-if-i-use-this-package based on the "imports" count. Both of these pieces of data were visible on the page only by scrolling, and if you wanted to know the details you could click through the link.
My suggestion would be to include the count in the tab bar. So, taking the above example, the tab bar entry for imports would say
Imports (20)
and the imported-by would sayImported By (123)
. Just to be clear, your tab bar would look like:I think that it's better to make the info available at a glance rather than now requiring more clicks to see the same thing. Thanks!
...Somewhat off the point but related is that, while the
Imported By
tab has counts on the page, theImports
tab is divided intoImports
andStandard Library Imports
with no counts next to them—at least for the package I chose as an example. It would be good to have counts in there.The text was updated successfully, but these errors were encountered: