How to call a java script

Hello,

I need to call a Java script file in Iframe but not able to do that in iOnic 3. Any pointers please?

Thank you

I’ve often heard @mhartington recommend against using iframes. Can you achieve your overarching goal some other way?

Hellloo…

Yes, I’d avoid using Iframes. Besides the security issues that could come up, it’s not a great user experience when you have an embeded frame.

I understand it is not the best solution. But i am trying to integrate Square payment provider and they use a nonce, which is generated by calling a Javascript in an IFrame. So, please suggest if we can do this in iOnic 3. I appriciate your answer.

Try to stay native with things like that. I found this: https://medium.com/the-web-tub/adding-payment-service-to-cordova-app-with-square-304bea8ad1f7

Would you be able to accomplish your all-encompassing objective some other way?