protected override void OnAppearing() { base.OnAppearing(); if (Sessions.Count == 0) { var sessions = SessionsDataSource.GetSessions(); foreach (var session in sessions) { Sessions.Add(session); } } }
public async Task LoadDataAsync() { await Task.Run(() => { if (Sessions.Count == 0) { var sessions = SessionsDataSource.GetSessions(); foreach (var session in sessions) { Sessions.Add(session); } } }); }