-
-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Calling native methods in NativeScript with multiple arguments #2653
Comments
It has to do with the way {N} maps to native function in Objective-c: I think this is what you need: It might help you to generate typescript type definitions for your module TNS_TYPESCRIPT_DECLARATIONS_PATH="${pwd}/typings" tns build ios from: https://docs.nativescript.org/runtimes/ios/how-to/Use-Native-Libraries |
@m-abs i went through the links, I get marshalling a bit, but it is for data types, and the second link doesn't give examples, I am using the cocoapods technique. My pods are working fine and methods with only one argument are working fine as well. What I am not getting is to call native methods with more than one argument, any example would help |
@m-abs just tried |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
I am trying to implement a plugin in NativeScript which uses a pod and pod has the following methods.
the basic usage works fine like this:
frameModule.topmost().ios.controller.view.makeToast("sometext");
but when i try to send multiple parameters for specific duration and position
frameModule.topmost().ios.controller.view.makeToast(toastObject.text, 5.0, CSToastPositionTop);
I get this exception in console
How do we send multiple parameters in to call native functions?
The text was updated successfully, but these errors were encountered: