Quantcast
Channel: Active questions tagged blazor - Stack Overflow
Viewing all articles
Browse latest Browse all 4839

How to render options for MudSelect?

$
0
0

I'm learning to use MudBlazor, and I'm starting with a simple MudSelect element like so:

<MudSelect Label="Select..." @bind-Value="_selectedFruitCode">    @foreach(var fruitCode in fruitCodes)    {        Console.WriteLine(fruitCode.Descr);<MudSelectItem Value=@fruitCode.Code>@projectCode.Descr</MudSelectItem>    }</MudSelect>

I see the fruits logged on the console, and I see that the selection defaults to the value I assign to _selectedFruitCode in the constructor, but when I click to make a selection, no selections appear.

What am I doing wrong?


Viewing all articles
Browse latest Browse all 4839

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>