dartdoc
dartdoc copied to clipboard
Search doesn't work for package:test
Attempting to search from the search box from https://pub.dev/documentation/test/latest/ seems to match mostly only the library names.
Even after navigating to a particular library, search won't work for names listed in that document. For example, if I go to https://pub.dev/documentation/test/latest/expect/expect-library.html and then try searching for throwsA, there are no results, even though throwsA is listed as part of the expect library.
This is particularly bad for package:test since package:test exports several other packages (and is the typical way that people consume those), there's been a history of stuff being moved around, and I can never remember which library owns the thing I'm looking for.
This is super strange. search was overhauled recently, but I don't think it's been pushed to pub. I'll keep an eye on this.
This is going to persist even with the search changes. I believe this is happening because package:test simply exports APIs from other packages, so dartdoc as ran by pub.dev doesn't see those elements as local, therefore it doesn't generate documentation for them, instead it cross-links to those package's own pub.dev documentation. This ends up with them not being added to the indexable list of items which is currently done alongside generation.
I guess search indexing would need to be separated from doc generation and take in account those externally linked packages.
I think that this seems to be working now.