using Scry.ViewModels;

namespace Scry.Views;

public partial class SettingsPage : ContentPage
{
    public SettingsPage(SettingsViewModel viewModel)
    {
        InitializeComponent();
        BindingContext = viewModel;
    }

    protected override async void OnAppearing()
    {
        base.OnAppearing();
        
        if (BindingContext is SettingsViewModel vm)
        {
            await vm.LoadCommand.ExecuteAsync(null);
        }
    }
}
