I start and stop a MediaRecorder stream. The red "recording" icon appears in the Chrome tab on start, but doesn't go away on stop.
The icon looks like this:
My code looks like this:
const mediaRecorder = new MediaRecorder(stream);
...
// Recording icon in the tab becomes visible.
mediaRecorder.start();
...
// Recording icon is still visible.
mediaRecorder.stop();
I also have a mediaRecorder.onstop
handler defined. It doesn't return anything or interfere with the event object.
What's the proper way to clear the "recording" indicator for a tab after starting and stopping a MediaRecorder instance?