Skip to content
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

Open Native iOS App from Nativescript screen #9

Closed
LSmint opened this issue Jun 20, 2018 · 4 comments
Closed

Open Native iOS App from Nativescript screen #9

LSmint opened this issue Jun 20, 2018 · 4 comments

Comments

@LSmint
Copy link

LSmint commented Jun 20, 2018

Is it possible to open a new screen of Native App view controller inside the NativeScript code?

@tdermendjiev
Copy link
Contributor

Hello @LSmint ,
Would you be able to provide me an example of what you are trying to achieve so I can better understand the question? Thank you.

@LSmint
Copy link
Author

LSmint commented Jun 21, 2018

Hi @tdermendjiev ,

Thanks for your response! Take an example, my app first startup screen was written in NativeScript. This main screen contains a button that can routes to a view controller where it was written in Native iOS (Swift). On the other hand, i can return back to the main page from Native app to NativeScript screen.
Really appreciated if you can provide me some advice!

@tdermendjiev
Copy link
Contributor

Hello @LSmint ,
If I understand correctly, you are trying to run Swift code in NS app. Currently the only way to achieve this is by creating a framework (or a cocoapod) and wrap it in a NativeScript plugin. Keep in mind that your Swift APIs have to be visible to the Objective-C runtime in order to access them from javascript. For more information see here.

@LSmint
Copy link
Author

LSmint commented Jun 22, 2018

Hi @tdermendjiev,

These all links really helpful for me to understand more how it works! Thanks for your advice!

@LSmint LSmint closed this as completed Jun 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants