TS Strict Collections
Closes
โ Pull Request Checklist:
- [ ] Included link to corresponding React Spectrum GitHub Issue.
- [ ] Added/updated unit tests and storybook for this change (for new code or code which already has tests).
- [ ] Filled out test instructions.
- [ ] Updated documentation (if it already exists for this component).
- [ ] Looked at the Accessibility Practices for this feature - Aria Practices
๐ Test Instructions:
๐งข Your Project:
Build successful! ๐
Build successful! ๐
Build successful! ๐
Build successful! ๐
Build successful! ๐
Build successful! ๐
Build successful! ๐
Build successful! ๐
Build successful! ๐
Build successful! ๐
## API Changes
@react-stately/collections
/@react-stately/collections:PartialNode
PartialNode <T> {
aria-label?: string
childNodes?: () => IterableIterator<PartialNode<T>>
element?: ReactElement
hasChildNodes?: boolean
index?: number
- key?: Key
+ key?: Key | null
props?: any
rendered?: ReactNode
renderer?: (T) => ReactElement
shouldInvalidate?: (unknown) => boolean
type?: string
value?: T
wrapper?: (ReactElement) => ReactElement
}
/@react-stately/collections:CollectionBuilder
CollectionBuilder <T extends {}> {
- build: (CollectionBase<{}>, unknown) => void
+ build: (Partial<CollectionBase<{}>>, unknown) => void
}
closing for https://github.com/adobe/react-spectrum/pull/7368