-
Notifications
You must be signed in to change notification settings - Fork 2.9k
Description
Problem
The @fluentui/react-components package represents the officially supported public API surface of Fluent UI React v9 yet it is composed on many "sub-packages" that are published on npm and follow semantic versioning, effectively making the APIs of these sub-packages part of Fluent's public API as well. Yet we don't always re-export an entire sub-package's API from @fluentui/react-components as parts of these APIs are meant for internal use only.
For example, @fluentui/react-components imports @fluentui/react-utilities and then re-exports some of its exports. Some of the exports from react-utilities are only meant for internal use and are not part of the public API but we have no way of communicating this to users our even within the Fluent UI team.
Appetite
3~4 weeks. We should have a solution prior to the release of v9 stable at the end of June.
Solution
Provide a mechanism to mark exports from a sub-package as "internal only".
Risks (Rabbit holes)
Out of scope (No-gos)
- No breaking changes allowed
Related
Tasks
- create api-stripping approach RFC | docs(rfc): add api access modifiers style-guide RFC for v9 #23577
- implement api stripping | feat: implement internal/alpha/beta/ API removals from package public API surface #23369
-
migrate packages to api stripping during build| will be closed by feat: enable@internalapi stripping in all packages and fix export maps #25319, Defined standard for v9 package file organization #24129 - remove all gradual migration required code when previous task is done | chore: remove unused logic used for gradual api-stripping migration #24127
- [Feature]: no-annotation lint rule #25694
- use lint rule in v9 packages