FreshMvvm icon indicating copy to clipboard operation
FreshMvvm copied to clipboard

Xamarin Forms 4 Compatibility

Open minaairsupport opened this issue 6 years ago • 12 comments

I am wondering if this library will be compatible with XF 4 with Shell experience

var welcomePage = FreshPageModelResolver.ResolvePageModel<WelcomePageModel>();

this error fired when I tried resolve viewModel

Note I change ContentPage to Shell

Resolve failed: WelcomePage - Reason: Specified cast is not valid. (FreshTinyIoC.TinyIoCResolutionException)
  at FreshTinyIoC.FreshTinyIoCContainer.ConstructType (System.Type requestedType, System.Type implementationType, System.Reflection.ConstructorInfo constructor, FreshTinyIoC.NamedParameterOverloads parameters, FreshTinyIoC.ResolveOptions options) [0x0015f] in <518460ffbfc5451e9dec2c932b3d8010>:0 
  at FreshTinyIoC.FreshTinyIoCContainer.ConstructType (System.Type requestedType, System.Type implementationType, FreshTinyIoC.NamedParameterOverloads parameters, FreshTinyIoC.ResolveOptions options) [0x00000] in <518460ffbfc5451e9dec2c932b3d8010>:0 
  at FreshTinyIoC.FreshTinyIoCContainer.ResolveInternal (FreshTinyIoC.FreshTinyIoCContainer+TypeRegistration registration, FreshTinyIoC.NamedParameterOverloads parameters, FreshTinyIoC.ResolveOptions options) [0x001ba] in <518460ffbfc5451e9dec2c932b3d8010>:0 
  at FreshTinyIoC.FreshTinyIoCContainer.Resolve (System.Type resolveType) [0x00011] in <518460ffbfc5451e9dec2c932b3d8010>:0 
  at FreshMvvm.FreshTinyIOCBuiltIn.Resolve (System.Type resolveType) [0x00000] in /Users/michaelridland/Projects/FreshMvvm/src/FreshMvvm/FreshTinyIOCBuiltIn.cs:48 
  at FreshMvvm.FreshPageModelResolver.ResolvePageModel (System.Type type, System.Object data, FreshMvvm.FreshBasePageModel pageModel) [0x00027] in /Users/michaelridland/Projects/FreshMvvm/src/FreshMvvm/FreshPageModelResolver.cs:41 
  at FreshMvvm.FreshPageModelResolver.ResolvePageModel[T] (System.Object data, T pageModel) [0x0000b] in /Users/michaelridland/Projects/FreshMvvm/src/FreshMvvm/FreshPageModelResolver.cs:25 
  at FreshMvvm.FreshPageModelResolver.ResolvePageModel[T] (System.Object initData) [0x0000b] in /Users/michaelridland/Projects/FreshMvvm/src/FreshMvvm/FreshPageModelResolver.cs:19 
  at FreshMvvm.FreshPageModelResolver.ResolvePageModel[T] () [0x00000] in /Users/michaelridland/Projects/FreshMvvm/src/FreshMvvm/FreshPageModelResolver.cs:12 
  at AgentWay.App.RegisterFirstPage () [0x00001] in /Users/mina/AgentWay.Mobile/AgentWay/App.xaml.cs:47 
  at AgentWay.App..ctor () [0x00016] in /Users/mina/AgentWay.Mobile/AgentWay/App.xaml.cs:32 
  at AgentWay.iOS.AppDelegate.FinishedLaunching (UIKit.UIApplication app, Foundation.NSDictionary options) [0x000fd] in /Users/mina/AgentWay.Mobile/AgentWay.iOS/AppDelegate.cs:80 
  at (wrapper managed-to-native) UIKit.UIApplication.UIApplicationMain(int,string[],intptr,intptr)
  at UIKit.UIApplication.Main (System.String[] args, System.IntPtr principal, System.IntPtr delegate) [0x00005] in /Library/Frameworks/Xamarin.iOS.framework/Versions/12.2.1.12/src/Xamarin.iOS/UIKit/UIApplication.cs:79 
  at UIKit.UIApplication.Main (System.String[] args, System.String principalClassName, System.String delegateClassName) [0x0002c] in /Library/Frameworks/Xamarin.iOS.framework/Versions/12.2.1.12/src/Xamarin.iOS/UIKit/UIApplication.cs:63 
  at AgentWay.iOS.Application.Main (System.String[] args) [0x00001] in /Users/mina/AgentWay.Mobile/AgentWay.iOS/Main.cs:17 

minaairsupport avatar Jan 03 '19 23:01 minaairsupport

@minaairsupport : Do you have a sample project that you can attach where it fails. It will helps us to get onto it sooner.

libin85 avatar Jan 25 '19 04:01 libin85

I dont have now but XF4 introduce new concept called Shell so we must be ready for using it , it will be stable soon

minaairsupport avatar Jan 27 '19 00:01 minaairsupport

@minaairsupport Thanks for the input, we will be working with the XF to ensure we support XF 4.0 and shell when it's released.

rid00z avatar Mar 21 '19 17:03 rid00z

have been released!

itoshinji avatar May 22 '19 05:05 itoshinji

Anyone tried using FreshMVVM with XF shell?

navkar avatar May 27 '19 22:05 navkar

@navkar I don't think XF Shell is in the current release of FreshMvvm. The guys are probably still working on it

gazwinter avatar May 28 '19 09:05 gazwinter

When it's released?

thiagoparabas avatar Jun 24 '19 13:06 thiagoparabas

@thiagoparabas as soon as you pitch in and help 👍

ghuntley avatar Jul 03 '19 09:07 ghuntley

I think once the below item has been completed, mvvm frameworks such as FreshMvvm can start working on it.

https://github.com/xamarin/Xamarin.Forms/issues/5166

rejy11 avatar Jul 26 '19 15:07 rejy11

any plane to support Shell?

minaairsupport avatar Mar 31 '20 15:03 minaairsupport

Yes, shell support will happen once Shell can support Mvvm.

rid00z avatar Apr 01 '20 06:04 rid00z

any news to support Shell mvvm ?

Geronatsios avatar Nov 07 '21 18:11 Geronatsios