Skip to content
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

[BUG] - Select: missing key attribute in the code example #3888

Closed
lucasromerodb opened this issue Oct 15, 2024 · 2 comments
Closed

[BUG] - Select: missing key attribute in the code example #3888

lucasromerodb opened this issue Oct 15, 2024 · 2 comments

Comments

@lucasromerodb
Copy link

lucasromerodb commented Oct 15, 2024

NextUI Version

2.4.2

Describe the bug

Missing key attribute in the code example (NextUI doc reference)

file to fix

key={animal.key}

Your Example Website or App

No response

Steps to Reproduce the Bug or Issue

Current

<Select
  items={animals}
  label="Favorite Animal"
  placeholder="Select an animal"
  className="max-w-xs"
>
  {(animal) => <SelectItem>{animal.label}</SelectItem>} 👈💥
</Select>

Expected behavior

Should be

<Select
  items={animals}
  label="Favorite Animal"
  placeholder="Select an animal"
  className="max-w-xs"
>
  {(animal) => <SelectItem key={animal.key}>{animal.label}</SelectItem>} 👈✅
</Select>

Screenshots or Videos

image

Operating System Version

Windows 11

Browser

Chrome

Copy link

linear bot commented Oct 15, 2024

@wingkwong
Copy link
Member

Fixed in #3883. Please wait for next release.

@wingkwong wingkwong closed this as not planned Won't fix, can't repro, duplicate, stale Oct 15, 2024
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 a pull request may close this issue.

2 participants