Skip to content
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

Rewrite react-conformance API to be more extensible/modular #21665

Closed
2 of 7 tasks
ecraig12345 opened this issue Feb 9, 2022 · 1 comment
Closed
2 of 7 tasks

Rewrite react-conformance API to be more extensible/modular #21665

ecraig12345 opened this issue Feb 9, 2022 · 1 comment
Labels
Area: Testing Fluent UI react (v8) Issues about @fluentui/react (v8) Fluent UI react-components (v9) Resolution: Soft Close Soft closing inactive issues over a certain period Type: Epic

Comments

@ecraig12345
Copy link
Member

ecraig12345 commented Feb 9, 2022

The API of @fluentui/react-conformance was designed with the intent of being extensible, but it's not a very good design. Also, it has the issue today of including tests in the core package that are actually specific to v8/v9/v0 (which can cause dependency graph issues and is generally unhelpful) and introducing enzyme+node types into the global namespace anywhere it's imported.

The new API will probably look something like this, inspired by babel:

isConformant({
  componentPath: '',
  presets: [
    // these will probably support a standard 'exclude' argument to disable rules
    basePreset({ /* strictly typed config options */ }),
    griffelPreset(),
  ],
  // possibly also 'plugins'/'rules' but this could maybe be combined with presets
})

This will be a breaking change to the conformance package. To help stage it, we may temporarily stop publishing the package (allowing all the breaking changes to be released together when ready). react-conformance is still 0.x, meaning we can break things in minors. We might release 1.0 once the refactor is done.

Conversion from enzyme to testing-library (#21663) will probably be done at the same time since it affects the public API.

Work items

Related items

@msft-fluent-ui-bot
Copy link
Collaborator

Because this issue has not had activity for over 150 days, we're automatically closing it for house-keeping purposes.

Still require assistance? Please, create a new issue with up-to date details.

@msft-fluent-ui-bot msft-fluent-ui-bot added the Resolution: Soft Close Soft closing inactive issues over a certain period label Aug 28, 2022
@microsoft microsoft locked as resolved and limited conversation to collaborators Sep 27, 2022
@Hotell Hotell removed the Resolution: Soft Close Soft closing inactive issues over a certain period label Mar 6, 2023
@Hotell Hotell reopened this Mar 6, 2023
@Hotell Hotell added Fluent UI react-components (v9) Fluent UI react (v8) Issues about @fluentui/react (v8) labels Mar 6, 2023
@microsoft-github-policy-service microsoft-github-policy-service bot added the Resolution: Soft Close Soft closing inactive issues over a certain period label Sep 3, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Area: Testing Fluent UI react (v8) Issues about @fluentui/react (v8) Fluent UI react-components (v9) Resolution: Soft Close Soft closing inactive issues over a certain period Type: Epic
Projects
None yet
Development

No branches or pull requests

3 participants