Messages not updating automatically until navigating to back or forward page in Ionic-cordova

We implemented Firebase in sample project also and we tested Notifications are coming as expected.But when user with in the chat page and sender sends a message to receiver “Typing” is working as expected but messages are not loading.

If user navigate back and come to chat screen then messages are loading. Same Happening in Sample app also.