diff --git a/core/src/components/reorder-group/readme.md b/core/src/components/reorder-group/readme.md index e03b854193..5905c1f810 100644 --- a/core/src/components/reorder-group/readme.md +++ b/core/src/components/reorder-group/readme.md @@ -88,6 +88,7 @@ The `detail` property of the `ionItemReorder` event includes all of the relevant ```javascript import { Component, ViewChild } from '@angular/core'; import { IonReorderGroup } from '@ionic/angular'; +import { ItemReorderEventDetail } from '@ionic/core'; @Component({ selector: 'reorder-group-example', @@ -99,7 +100,7 @@ export class ReorderGroupExample { constructor() {} - doReorder(ev: any) { + doReorder(ev: CustomEvent) { // The `from` and `to` properties contain the index of the item // when the drag started and ended, respectively console.log('Dragged from index', ev.detail.from, 'to', ev.detail.to); @@ -121,6 +122,7 @@ export class ReorderGroupExample { ```javascript import { Component, ViewChild } from '@angular/core'; import { IonReorderGroup } from '@ionic/angular'; +import { ItemReorderEventDetail } from '@ionic/core'; @Component({ selector: 'reorder-group-example', @@ -134,7 +136,7 @@ export class ReorderGroupExample { constructor() {} - doReorder(ev: any) { + doReorder(ev: CustomEvent) { // Before complete is called with the items they will remain in the // order before the drag console.log('Before complete', this.items); diff --git a/core/src/components/reorder-group/usage/angular.md b/core/src/components/reorder-group/usage/angular.md index 43111202e6..f5773e44fd 100644 --- a/core/src/components/reorder-group/usage/angular.md +++ b/core/src/components/reorder-group/usage/angular.md @@ -72,6 +72,7 @@ ```javascript import { Component, ViewChild } from '@angular/core'; import { IonReorderGroup } from '@ionic/angular'; +import { ItemReorderEventDetail } from '@ionic/core'; @Component({ selector: 'reorder-group-example', @@ -83,7 +84,7 @@ export class ReorderGroupExample { constructor() {} - doReorder(ev: any) { + doReorder(ev: CustomEvent) { // The `from` and `to` properties contain the index of the item // when the drag started and ended, respectively console.log('Dragged from index', ev.detail.from, 'to', ev.detail.to); @@ -105,6 +106,7 @@ export class ReorderGroupExample { ```javascript import { Component, ViewChild } from '@angular/core'; import { IonReorderGroup } from '@ionic/angular'; +import { ItemReorderEventDetail } from '@ionic/core'; @Component({ selector: 'reorder-group-example', @@ -118,7 +120,7 @@ export class ReorderGroupExample { constructor() {} - doReorder(ev: any) { + doReorder(ev: CustomEvent) { // Before complete is called with the items they will remain in the // order before the drag console.log('Before complete', this.items);