The state read-only property of the AudioEncoder interface returns the current state of the underlying codec.
state
MDN Reference