-
Notifications
You must be signed in to change notification settings - Fork 4.3k
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
Divider
: migrate from reakit
to @ariakit/react
#55622
Conversation
Divider
: refactor from reakit
to @ariakit/react
Divider
: migrate from reakit
to @ariakit/react
5e0fca2
to
c23e881
Compare
@@ -2,7 +2,7 @@ | |||
* External dependencies | |||
*/ | |||
// eslint-disable-next-line no-restricted-imports | |||
import type { SeparatorProps } from 'reakit'; | |||
import type { SeparatorProps } from '@ariakit/react'; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like the SeparatorProps
from ariakit
include the as
and render
props, which we don't want to expose.
We can easily fix this by adding 'as'
and 'render'
to the list of omitted props on line 14, but it would be also interesting to know if there;s any particular reason why previously we were not picking up the as
prop from SeparatorProps
, and now we are.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I applied your suggestions via 7d0b7ce – I'm a bit unsure about the rationale you mentioned.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Apologies in case I wasn't clear. What I was trying to say is that I was curious to know the reason why previously, when using reakit
types, the as
prop was not being picked up from SeparatorProps
. I guess the answer is simply because SeparatorProps
did not include the as
prop .
c23e881
to
7d0b7ce
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
7d0b7ce
to
2f73f98
Compare
Flaky tests detected in 9dfeb1b. 🔍 Workflow run URL: https://github.com/WordPress/gutenberg/actions/runs/6771508073
|
83ac384
to
9dfeb1b
Compare
What?
Migrate
Divider
fromreakit
toariakit
.Why?
Part of #53278
As stated in the linked issue Reakit does not explicitly support React 18 (causing peer dependency warnings) and Reakit has already been succeeded by Ariakit, so it will not receive any more updates.
How?
In this case we switch out the Reakit for the Ariakit imports.
Testing Instructions