So I have been following the github repo(https://github.com/cordova-sms/cordova-sms-plugin) for the Ionic Native SMS plugin, and I have configured as to the repo suggests with:
var options = {
replaceLineBreaks: false, // true to replace \n by a new line, false by default
android: {
intent: 'INTENT' // send SMS with the native android SMS messaging
//intent: '' // send SMS without opening any other app
}
};
however, when I test it on a real device, it still does not send a SMS.
can anyone help me, do I need to add in a permission? Here is the code that I have so far
sendSms() {
let options = {
replaceLineBreaks: false, // true to replace \n by a new line, false by default
android: {
intent: '' // send SMS with the native android SMS messaging
// intent: '' // send SMS without opening any other app
}
};
this.sms.send('656225667', 'SMS Works', options).then(val => {
alert('It works');
});
}