Author : HASSAN MD TAREQ

EditForm requires a Model parameter, or an EditContext parameter, but not both

Reason: declared model variable in @code{} or code behind but did not instantiate it

Solution: instantiate model in OnInitialized() before using for binding i.e. CreateEmailModel = new CreateEmailModel()

    public class CreateBase: ComponentBase
    {
        protected CreateEmailModel CreateEmailModel { get; set; }


        protected override void OnInitialized()
        {
            CreateEmailModel = new CreateEmailModel();
        }

        protected void OnValidSubmission(EditContext editContext)
        {
            // ... ... ...
        }
    }