I believe what you are asking is; if user A is typing a message to User B, you want User B to see a message 'User A is Typing' or something along those lines.
You can leverage Firebase to handle this yes - we do Mac development but I would think it would be a similar concept across platforms. The bulk of the logic is implemented on the device, not in Firebase however.
Firebase would be used as the notification mechanism to notify the user that something being typed into a text field or a user is no longer typing.
On OSX, we have textfield's (NSTextField) that can detect when the field has begun or ended editing, a delegate method is called 'controlTextDidBeginEditing' when User A begins typing.
In that method, a flag or other info could be written to a Firebase node indicating say, the user id ( uid ) or name of the user that's typing, time, date, phase of the moon or whatever.
User B is observing that Firebase Node so when a child is added, edited or changed they are notified and can display the appropriate message.
Likewise, User A is also observing a Firebase node so it will know when User B is typing.
When the user is done typing (editing the field) (OS X controlTextDidEndEditing) data could be written to Firebase to indicate the user is done typing. Again, the other user is observing changes, additions or edits to that node so it will always be apprised of what's going on.
You could keep all of the chatting data in firebase if you need traceability in the future, or you could have the nodes delete themselves when the user logs off or terminates the conversation.