<h1>Counter</h1>

<p>Current count: @currentCount</p>

<Button class="btn btn-primary" OnClick="IncrementCount">Click me</Button>

@code {
    private int currentCount = 0;

    private void IncrementCount()
    {
        throw new Exception("Custom Exception");
    }
}
