Closed fredguth closed 8 months ago
I am not able to reproduce what you're describing.
When I bind:value
to the <Command.Input />
I am getting the expected behavior. Can you provide a reproduction?
Are you definitely binding to<Command.Input />
and not <Command.Root />
? I made that mistake at first as well.
But yeah, binding to <Command.Input />
works as expected for me.
I am probably doing something wrong. Here is a MWE: https://github.com/fredguth/cmd_mwe/blob/main/src/routes/plus/%2Bpage.svelte
@fredguth I believe you need to directly bind to the Command.Input
value
prop inside this component and then export it as an explicit prop. Then you should be able to bind to it in the parent component.
Thank you all ! I guess @huntabyte already published a fix in shadcn-svelte.
Thanks for raising the issue @fredguth! Glad its all worked out!
I am trying to access the search input value. Binding to value in Command.Input binds to the selected Item.