Answers for "ionic play notification sound"

0

ionic play notification sound

import { NativeRingtones } from '@ionic-native/native-ringtones/ngx';


constructor(private ringtones: NativeRingtones) { }

...
this.ringtones.getRingtone().then((ringtones) => { console.log(ringtones); });

this.ringtones.playRingtone('assets/ringtones/sound_1.caf');

this.ringtones.stopRingtone('assets/ringtones/sound_1.caf');
Posted by: Guest on April-23-2020

Browse Popular Code Answers by Language