Replies: 2 comments 3 replies
-
@pavelbe Does downgrading the cmdk work for you ? |
Beta Was this translation helpful? Give feedback.
1 reply
-
This problem is caused by a breaking change in the cmdk package. Check the source here: https://github.com/pacocoursey/cmdk/releases/tag/v1.0.0 Now is required to use the CommandList component wrapping the CommandGroup. Check this example: Change from this: <Command>
<CommandInput placeholder="Search framework..." />
<CommandEmpty>No framework found.</CommandEmpty>
<CommandGroup>
{frameworks.map((framework) => (
<CommandItem key={framework.value}>
{framework.label}
</CommandItem>
))}
</CommandGroup>
</Command> To this: <Command>
<CommandInput placeholder="Search framework..." />
<CommandEmpty>No framework found.</CommandEmpty>
<CommandList>
<CommandGroup>
{frameworks.map((framework) => (
<CommandItem key={framework.value}>
{framework.label}
</CommandItem>
))}
</CommandGroup>
</CommandList>
</Command> |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hello shadcn ui team and community! 👋
I've encountered an issue after updating the cmdk library from version 0.2.1 to 1.0.0 in a project that utilizes the Command, CommandGroup, CommandItem, CommandEmpty, and CommandInput components from @/components/ui/command. Everything worked fine before the update, but after upgrading, the following error surfaced:
I attempted to update the Command components, but it didn't resolve the issue. It seems that the upgrade to cmdk version 1.0.0 introduced changes that may require additional actions from the shadcn ui developers to ensure compatibility. 🛠️
I would greatly appreciate any advice or suggestions on how to address this issue. 🙏 Are there updates or patches that I might have missed? Or perhaps specific changes are needed in the project code to adapt to the new version of cmdk? 🔍
Thank you for your time and assistance! 🙌
Beta Was this translation helpful? Give feedback.
All reactions