[~vsazel] [~supittma] Not sure if you guys know about this, but apparently Xamarin can support native iOS and Android libraries using bindings:
ios: https://docs.microsoft.com/en-us/xamarin/ios/platform/binding-objective-c/walkthrough?tabs=vsmac android: https://docs.microsoft.com/en-us/xamarin/android/platform/binding-java-library/
Swift is not supported by Xamarin itself, but it can be done as described in this post: https://medium.com/@Flash3001/binding-swift-libraries-xamarin-ios-ff32adbc7c76.
So if this works, if means we actually don't need to rewrite all the modules in C#. We just need to provide the binding project. We can still publish the modules to NuGet or Xamarin Components. This is how OkHttp is supported by Xamarin: https://github.com/mattleibow/square-bindings.
I think to understand which approach is better, especially for developer experience, can we do a little spike using the core module:
1. we will still implement the core module. But we only implement the bare minimum - parse the config file. We should only need to write the code once and it should work on both iOS and Android. 2. We build it and maybe publish it to NuGet/Xamarin component. 3. We update the example app and use it and see how it works.
We also implement another one by creating bindings: 1. We create binding projects using the iOS and Android Core module 2. Publish it 3. Use it in the example app.
We can then compare the 2 approaches in these aspects:
1. complexity 2. maintainability 3. developer experience 4. any other importing things
We should aim at writing a proposal based on the findings from this spike. Hopefully it will give us clear indication on which approach we should take before we starting implementing other modules.
WDYT? |
|