Quantcast
Channel: Ionic Forum - Latest topics
Viewing all articles
Browse latest Browse all 70795

Best way to replace deprecated Events

$
0
0

@leonardofmed wrote:

Currently I’m using events to access MyComponent’s functions from MyPage. I’m using this way:

In MyPage:

randomFunction() {
	this.events.publish('functionCall:myPageRandomFunction');
}

In MyComponent:

this.events.subscribe('functionCall:myPageRandomFunction', (eventData) => {
    //Doing things here
}

How I’m supposed to replace this methodology now that the events is deprecated? Should I use Observables? If yes, how can I ensure the same functionality?

Posts: 2

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 70795

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>