using Microsoft.AspNetCore.Components;

namespace BlazorServer.Pages
{
    public partial class StaticCounter
    {
        [Parameter]
        public int Start { get; set; } = -1;
        private static int currentCount = 0;

        private void IncrementCount()
        {
            currentCount++;
        }

        protected override void OnInitialized()
        {
            if (Start >= 0)
            {
                currentCount = Start;
            }
        }
    }
}