 events are defined by the developer. Consider the following <strong>BlazorDiceRoll.razor</strong> component:</p>
<pre language="razor">&lt;button type="button" @onclick="RollTheDice"&gt;Roll Dice!&lt;/button&gt;

@code {
    [Parameter]
    public EventCallback&lt;int&gt; OnDiceRolled { get; set; }

    public void RollTheDice() =&gt; OnDiceRolled.InvokeAsync(new Random().Next(1, 6));
}</pre>
<p>In this example, we created the <code>OnDiceRolled</code> event on top of the HTML <code>onclick</code> event. T