Would it be possible to use React Native and Xamarin in one app.
You can look at this in two ways.
RCTRootView
in such a way that Xamarin can initialize it and load the js bundle. Does this mean that all other react types need to be bound as well? Or would RCTRootView
be sufficient?RCTViewManager
on iOS or ViewManager
on Android.Why would you want to do this? Maybe because you want to extend an existing Xamarin app with a new section in react native. Maybe because you like writing customer views better in C# than in Swift or Java. Or maybe just because you want to convolute things ;-)
So are there technical issues which would make this impossible (like macro's)? Or is this technically possible but just very cumbersome to get going? Or can this be done?
Development languages Xamarin uses . Net languages, such as C# and F#, which are common languages and can be used to write native platform code. React Native uses JavaScript, which was not invented for it, but it still does a great job with React Native apps.
As long as we are building our application purely within the framework, we can drive our app with properties and callbacks. But, when we mix React Native and native components, we need some specific, cross-language mechanisms that would allow us to pass information between them.
Though both Xamarin and React Native offer near-native performance, Xamarin runs the fastest code on Android and iOS and has a user interface (UI) for using native tools. TLDR: In Xamarin vs. React Native, Xamarin has more brownie points for native-like performance. Xamarin wins.
Moreover, Xamarin is native, and because it gives access to 100 percent of the native APIs, developers can also create Android wear apps, Apple Watch apps, and Apple TV apps.
How to integrate a React Native View into any existing iOS or Android application is well documented, so this should definitely be possible.
You may want to also take a look at Wix's react-native-navigation as they have broken out of the standard "unique view" from React Native.
Also, someone made it possible to use Cordova plugins in a React Native application, as an example on how to do it the other way around.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With