react-aria/react-stately upgrade & versioning updates#1557
Conversation
🦋 Changeset detectedLatest commit: df8337f The changes in this PR will be included in the next version bump. This PR includes changesets to release 14 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Review the following changes in direct dependencies. Learn more about Socket for GitHub.
|
|
Warning Review the following alerts detected in dependencies. According to your organization's Security Policy, it is recommended to resolve "Warn" alerts. Learn more about Socket for GitHub.
|
d3e423a to
f2311cc
Compare
3a3c040 to
19824c8
Compare
19824c8 to
df8337f
Compare
This makes
@keystar/uiuse the newer versions ofreact-ariaandreact-statelywhich are just single packages which should significantly reduce the number of installed dependencies.The newer packages also put some APIs that previously weren't marked private behind
/privateentrypoints, since these naturally might break in newer versions I've pinned them to exact versions, this should solve various issues we've had in the past where something changed in a non-major version of react-aria/react-stately and that broke Keystatic in some way because the version requirements were loose.I've also added optional peer dependencies on
react-ariaandreact-statelyfrom@keystar/uiand onreact-aria,react-statelyand@keystar/uifrom@keystatic/core. Note I haven't removed the normal dependencies on these though so essentially if you don't depend on these yourself, things just work but if you e.g. use@keystar/uito make UI for a custom field, you need to have the exactly matching version of@keystar/uiinstalled. This isn't changing things practically since things already broke previously if you had mismatched versions but this makes the requirement explicit so users will get a peer dependency warning/error if it's wrong.This is similar to how
react-domrequires a matching version ofreactbutreact-domdoesn't do major versions for requiring a newer version ofreact.In the future, we may want to migrate to
react-aria-componentsso we're only using public APIs and can potentially be looser with the version requirements but I haven't done that here.