Skip to content

docs(ComboBox): document defaultFilter's default contains filter#10222

Open
patrickwehbe wants to merge 3 commits into
adobe:mainfrom
patrickwehbe:docs/combobox-defaultfilter-default
Open

docs(ComboBox): document defaultFilter's default contains filter#10222
patrickwehbe wants to merge 3 commits into
adobe:mainfrom
patrickwehbe:docs/combobox-defaultfilter-default

Conversation

@patrickwehbe

Copy link
Copy Markdown

Closes

Closes #10065

Description

The React Aria Components ComboBox's defaultFilter prop didn't document its default, so the generated props table gave no hint about what filtering happens out of the box. As confirmed in the issue, when defaultFilter isn't provided the component falls back to the contains filter from useFilter (defaultFilter: props.defaultFilter || contains).

This documents that default in the prop's JSDoc, and fixes a small grammar slip in the same comment ("if a option" → "if an option").

Comment thread packages/react-aria-components/src/ComboBox.tsx Outdated
@snowystinger

Copy link
Copy Markdown
Member

Looks like you need to sign the CLA. https://github.com/adobe/react-spectrum/blob/main/CONTRIBUTING.md#contributor-license-agreement

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

React Aria ComboBox filters items but docs state it doesn't

2 participants