Slide 11
Slide 11 text
Alertの動作 (ios版)
export default {
//省略
methods: {
presentAlertConfirm() {
return this.$ionic.alertController
.create({
cssClass: ‘my-custom-class’,
header: ‘通知’,
subHeader: ‘通知許可してくれたら嬉しい!',
message: 'このアプリに通知を許可しますか?',
buttons: [
{
text: 'キャンセル',
role: 'cancel',
handler: () => {
this.notice = false
},
},
{
text: 'OK',
handler: () => {
this.notice = true
},
},
],
})
.then(a => a.present())
},
}
}