EternallLight / cordova-plugin-openwith-ios

A modified version of the Cordova iOS Share extension (cordova-plugin-openwith) by Jean-Christophe Hoelt for iOS. Supports receiving shared URLs, text and images as well as sharing several images at once.
https://web-mystery.com/
MIT License
28 stars 84 forks source link

How to use this plugin in Ionic 3? #9

Open soubhikchatterjee opened 5 years ago

soubhikchatterjee commented 5 years ago

I have managed to get my ionic app in the "Share List" in ios, but my problem is the code you mentioned in the "Usage" section of the readme, I have copied the entire code in the constructor of my home.ts file but typescript is complaining with an error message "[ts] Cannot find name 'cordova'."

Please tell me how can i use this plugin in my Ionic 3 app?

Many thanks in advance.

Flucadetena commented 5 years ago

hey @soubhikchatterjee the way to use it in Ionic 3 is to use: (<any>window).plugins instead of cordova. For example: this: (<any>window).plugins.openwith.setLoggedIn(true); Instead of: corodva.openwith.setLoggedIn(true);

I know this works, but i'm getting this other error: "The executable was signed with invalid entitlements".

If you manage to make it work please let me know and help. Thanks.

rafaelmrdyn commented 4 years ago

"declare let cordova;" on the top of file