private void Page_Loaded(object sender, RoutedEventArgs e)
 {
     ForView.Unwrap<OnboardingViewModel>(DataContext, vm =>
     {
         _lastException = new Computed<string>(() => vm.LastException);
         _subscription = _lastException.Subscribe(v => { if (v != null) { ShowError.Begin(); } });
     });
 }
 private void Page_Loaded(object sender, RoutedEventArgs e)
 {
     ForView.Unwrap<SubscriptionViewModel>(DataContext, vm =>
     {
         _state = new Computed<string>(() => vm.HasSelectedSubscription
             ? "ShowDetail"
             : "ShowMaster");
         _stateSubscription = _state.Subscribe(s =>
         {
             VisualStateManager.GoToState(this, s, _isInitialized);
             _isInitialized = true;
         });
     });
 }
        private void Page_Loaded(object sender, RoutedEventArgs e)
        {
            ForView.Unwrap<SearchViewModel>(DataContext, vm =>
            {
                _state = new Computed<string>(() => vm.HasSelectedSearchResult
                    ? "ShowDetail"
                    : "ShowMaster");
                _stateSubscription = _state.Subscribe(s =>
                {
                    VisualStateManager.GoToState(this, s, _isInitialized);
                    _isInitialized = true;
                });

                _lastException = new Computed<string>(() => vm.LastException);
                _subscription = _lastException.Subscribe(v => { if (v != null) { ShowError.Begin(); } });
            });
        }