Last active
August 31, 2017 09:43
-
-
Save chandanch/43a94ea9ce64c06b4712a6412c02508c to your computer and use it in GitHub Desktop.
Handling events in root component
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export class MyApp { | |
| constructor(private platform : Platform) { | |
| this.platform.Ready().then(() => | |
| this.handleEvents(); | |
| ) | |
| } | |
| handleEvents() { | |
| this.events.subscribe("navigation", (eventData)=> { | |
| this.nav.push(eventData.page, eventData.data) | |
| }); | |
| this.events.subscribe("modalPopup", (eventData) => { | |
| this.nav.push(eventData.modal, eventData.data | |
| }); | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment