Skip to content

Select component dont display selected values #278

Answered by PH7-Jack
KevinEscobarV asked this question in BUG
Discussion options

You must be logged in to vote

@KevinEscobarV
Could you try to pass the id as a number?
The WireUI Select uses a strict comparison. The value "1" is not equal to 1
You can pass a number using :value="1"

<x-select label="Select a disease" placeholder="Select an option"
                    wire:model.defer="model" multiselect>
                    @foreach ($diseases as $disease)
                        <x-select.option :label="$disease->name" :value="$disease->id" />
                    @endforeach
</x-select>

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by KevinEscobarV
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
BUG
Labels
None yet
2 participants