public Task CalendarInit(string elementName, CalendarSettings settings, DotNetObjectReference <ComponentBase> dotNetRef = null) { try { jsRuntime.InvokeAsync <ElementReference>( "BlazorFullCalendar.interop.calendarInit", elementName, settings.ToJson(), dotNetRef ); return(Task.CompletedTask); } catch { return(Task.CompletedTask); } }
public async Task CalendarInitAsync(CalendarSettings settings, DotNetObjectReference <FullCalendar> dotNetRef) { try { await _jsRuntime.InvokeVoidAsync( "BlazorFullCalendar.addFCWrapperInstance", _calendarDivId, settings.ToJson(), dotNetRef ); return; } catch (Exception ex) { Console.WriteLine(ex); return; } }