diff --git a/src/components/alert/alert-controller.ts b/src/components/alert/alert-controller.ts index 6d8c83de6f..4e02604c50 100644 --- a/src/components/alert/alert-controller.ts +++ b/src/components/alert/alert-controller.ts @@ -51,12 +51,10 @@ import { Config } from '../../config/config'; * ```ts * import { AlertController } from 'ionic-angular'; * - * constructor(private alertCtrl: AlertController) { - * - * } + * constructor(public alertCtrl: AlertController) { } * * presentAlert() { - * let alert = this.alertCtrl.create({ + * const alert = this.alertCtrl.create({ * title: 'Low battery', * subTitle: '10% of battery remaining', * buttons: ['Dismiss'] @@ -65,7 +63,7 @@ import { Config } from '../../config/config'; * } * * presentConfirm() { - * let alert = this.alertCtrl.create({ + * const alert = this.alertCtrl.create({ * title: 'Confirm purchase', * message: 'Do you want to buy this book?', * buttons: [ @@ -88,7 +86,7 @@ import { Config } from '../../config/config'; * } * * presentPrompt() { - * let alert = this.alertCtrl.create({ + * const alert = this.alertCtrl.create({ * title: 'Login', * inputs: [ * { @@ -181,14 +179,14 @@ import { Config } from '../../config/config'; * out first, *then* start the next transition. * * ```ts - * let alert = this.alertCtrl.create({ + * const alert = this.alertCtrl.create({ * title: 'Hello', * buttons: [{ * text: 'Ok', * handler: () => { * // user has clicked the alert button * // begin the alert's dismiss transition - * let navTransition = alert.dismiss(); + * const navTransition = alert.dismiss(); * * // start some async method * someAsyncOperation().then(() => {