Open
Description
Steps to reproduce the good godoc.org behavior:
- Go to https://godoc.org/github.com/dgraph-io/badger
- Press Ctrl-F (or whichever "search in page" shortcut)
- Type "NewIterator"
- Get taken straight to "func (txn *Txn) NewIterator(opt IteratorOptions) *Iterator", its first occurrence - in the index
Now, on pkgsite:
- Go to https://pkg.go.dev/github.com/dgraph-io/badger/v2@v2.2007.2
- Press Ctrl-F (or whichever "search in page" shortcut)
- Type "NewIterator"
- The first result is about a quarter of the page in, but I don't see a match. Weird. Press enter again for the next match.
- Still an invisible/hidden match. I have to press enter a few more times to get taken to the index, the visible result I want.
Another way to look at it is that the search on godoc.org results in 6 matches, but the same search results in 10 matches on pkgsite. The first four matches are hidden, which make up for the difference with godoc.org.
Can we get rid of those four hidden matches altogether? Especially since they somehow match before the index, which is very close to the top.