Skip to content

Fix duplicate entries of elements in a category when re-exported. #4043

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

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

jonasfj
Copy link
Member

@jonasfj jonasfj commented Apr 30, 2025

If a package has two libraries foo.dart and bar.dart where

  • foo.dart contains Foo with an /// {@category ...} annotation, and,
  • bar.dart re-exports foo.dart.

Then the category page shall not list Foo twice, which is simply a bug.

This change fixes this issue.


There is an example of the issue in production here:
https://pub.dev/documentation/typed_sql/latest/topics/Exceptions-topic.html

image

If a package has two libraries `foo.dart` and `bar.dart` where
 * `foo.dart` contains `Foo` with an `/// {@category ...}` annotation,
   and,
 * `bar.dart` re-exports `foo.dart`.

Then the category page shall not list `Foo` twice, which is simply a
bug.

This change fixes this issue.
@jonasfj jonasfj requested a review from szakarias April 30, 2025 10:55
Copy link
Member

@srawlins srawlins left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice!

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.

2 participants