FreshMVVM getting started the missing step

I have been playing around with FreshMVVM and found I like it a lot. It is very light weight and fairly easy to use.
There is one thing missing from the FreshMVVM quick start that I felt should blog about. You need to put everything in a fresh navigation container if you want the pages and page models to resolve and of course be able to navigate.
http://www.michaelridland.com/xamarin/freshmvvm-quick-start-guide/
In the app class this is how you need to set MainPage to an instance to show the first page.

    public App()
    {
        // The root page of your application
        var homePage = FreshMvvm.FreshPageModelResolver.ResolvePageModel<HomePageModel>();
        var navConatiner = new FreshMvvm.FreshNavigationContainer(homePage);
        MainPage = navConatiner;
    }

Comments