feat(social-sharing): Add missing method shareViaWhatsAppToPhone(#3513)

This commit is contained in:
Sidnei Luiz Becker 2020-10-16 14:22:25 -03:00 committed by GitHub
parent 5a77eabf76
commit f3ce3c4930
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -282,4 +282,21 @@ export class SocialSharing extends IonicNativePlugin {
saveToPhotoAlbum(fileOrFileArray: string | string[]): Promise<any> {
return;
}
/**
* Shares directly to a WhatsApp Contact with phone number.
* @param phone {string} Pass phone number
* @param message {string} Message to send
* @param fileOrFileArray fileOrFileArray Single or multiple files
* @param url {string} Link to send
* @returns {Promise<any>}
*/
@Cordova({
successIndex: 5,
errorIndex: 6,
platforms: ['iOS', 'Android'],
})
shareViaWhatsAppToPhone(phone: string, message: string, fileOrFileArray: string | string[], url?: string): Promise<any> {
return;
}
}