flushAsync

The flush() method of the VideoEncoder interface forces all pending encodes to complete.

MDN Reference