I have been struggeling with this.
I'm trying to move my toolbar item commands to my viewmodel
Right now my code is like this
` public class SwipePageViewModel : BaseViewModel
{
public ICommand ShowBaskedCommand { get; private set; }
public SwipePageViewModel()
{
ShowBaskedCommand = new Command(ShowBasket);
}
private void ShowBasket()
{
Navigation.PushAsync(new HomePage() {Title = AppResources.Page2});
}
}`
My problem is that Navigation is not found in my view model. And therefore I can't push my view.
What to do?