-
Notifications
You must be signed in to change notification settings - Fork 44
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Early / Eager SDK Initialization from Native Code #121
Comments
Hi @buschtoens Sorry for a bit delayed response. It's a nice idea, but in current state of things not really achievable because our callback definition mechanism "ties you" to define them in place where you perform configuration object creation and SDK initialisation (in your example from above, the native world). But this might be interesting feature to add. What we might do (this is actually what we are doing for all getters for next major SDK release) is to add asynchronous getter to Adjust interface which you can use to get (in this case) deferred deep link and that SDK triggers it as soon as it gets in possession of deferred deep link. Upcoming 5.0.0 release will have this for sure, but we will also check how feasible this might be in current 4.x.x version. Will keep you posted. Btw, +1 from my end on idea on how to "speed up" deferred deep link obtaining in your Cordova/Capacitor layer. It's pretty cool idea, but just huge majority of people is unwilling to take down this road and mess with native code at all. Cheers |
Thanks for getting back to me! We experimented with initializing the config early from the native side and registering fake listeners for all the |
Absolutely. PRs are always more than welcomed and if you end up with something which solves the issue, feel free to submit it and we're gonna check it out and if all works well, add to one of next releases. |
If Adjust lies on a time-critical path, as could be the case for e.g. the deferred deep link callback, it would be desirable to initialize the SDK as early as possible, to minimize the time to wait until the callback resolves.
I'd love, if there were convenient way to initialize the SDK from the native code, before the Cordova / Capacitor WebView even starts loading, and then still allow the WebView to register callback listeners.
The text was updated successfully, but these errors were encountered: