Skip to content

Conversation

@amantoppo1739
Copy link

Added a warning note to the useSelect documentation clarifying that it does not manage the component's value state, addressing user confusion in issue #7121.

PR Checklist

Please check if your PR fulfills the following requirements:

Bugs / Features

What is the current behavior?

What is the new behavior?

fixes (issue)

Notes for reviewers

Added a warning note to the useSelect documentation clarifying that it does not manage the component's value state, addressing user confusion in issue refinedev#7121.
@amantoppo1739 amantoppo1739 requested a review from a team as a code owner December 10, 2025 10:51
@changeset-bot
Copy link

changeset-bot bot commented Dec 10, 2025

⚠️ No Changeset found

Latest commit: e681bd7

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@amantoppo1739
Copy link
Author

I noticed the Commitlint check failed, likely because my description line was too long. Since I submitted this via the GitHub Web UI, I can't easily amend the commit message. I'm happy to close and reopen if strict compliance is required, otherwise I assume this can be fixed via squash-merge!

Copy link
Member

@alicanerdurmaz alicanerdurmaz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We don't have [!NOTE] component.
image

Comment on lines 21 to 27
> [!NOTE]
> The `useSelect` hook is designed primarily for data fetching (managing options, loading, pagination). It does not manage the controlled state (the selected value) of the component.
> [!NOTE]
> If you are using the `<Select>` component standalone, you must manage the `value` and `onChange` props using `useState`. If you are using it within a Form (like Ant Design's `<Form>`), the form item will handle the state for you.
Here is a basic example that uses the `useSelect` hook.
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe these can be one paragraph.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the review! I've updated the formatting to use :::info (since [!NOTE] isn't supported) and condensed the text into a single paragraph as requested.

Copy link
Member

@alicanerdurmaz alicanerdurmaz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the improving Refine. I left 2 comment, Please check when you have time

Updated the documentation for the useSelect hook to clarify its purpose regarding state management and data fetching.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants