microsoft / microsoft/fluentui
[Feature]: add custom style hooks support only to stable packages
Open
Nobody has claimed this yet.
Area: Build System
Fluent UI react-components (v9)
NX: workspace generators
Resolution: Soft Close
Type: Feature
- Dominant language
- TypeScript
- Stars
- 20.3k
- Forks
- 2.9k
- Avg merge
- 2d 9h
- Merged PRs (30d)
- 46
Description
Library
React Components / v9 (@fluentui/react-components)
Describe the feature that you would like added
- we keep functionality as it
- we don't add hooks to the shared interface (
@fluentui/react-shared-contexts) while packages are in preview phase@fluentui/react-*-preview
Tasks:
- update generators
- lint rule to dissalow extends https://github.com/microsoft/fluentui/blob/master/packages/react-components/react-shared-contexts/src/CustomStyleHooksContext/CustomStyleHooksContext.ts#L8 for preview packages
- add types+global hooks automatically to CustomStyleHooksContext.ts https://github.com/microsoft/fluentui/issues/29775#issuecomment-1798682516
Have you discussed this feature with our team
No response
Additional context
No response
Validations
- Check that there isn't already an issue that request the same feature to avoid creating a duplicate.
Priority
Normal
Related issues
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the generator changes already completed and inspect packages/react-components/react-shared-contexts/src/CustomStyleHooksContext/CustomStyleHooksContext.ts. Trace how preview packages are identified and how lint rules are configured. Done means preview packages cannot extend the shared context, while stable packages receive the required types and global hooks automatically.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- developer-experience, tooling
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100