capacitor
capacitor copied to clipboard
WIP: resolve to accept other data types
This is a first attempt to allow PluginCall.resolve to accept other data types than JSObject.
From what I can see in the native-bridge, it should already handle any value coming "fromNative":
https://github.com/ionic-team/capacitor/blob/main/android/capacitor/src/main/assets/native-bridge.js#L420
So, simply overriding sendReponseMessage to accept other values than PluginResult seems like it should be enough.
This of course needs further development, but I would like some feedback from the maintainers on whether this approach is reasonable (and so I would proceed) or if this is just a bad idea.#5267
This should partially fix #1132