BufHidden

The BufHidden event:

Fires:

radio_button_unchecked

Before a buffer becomes hidden, when there are no longer windows that show the buffer, but the buffer is not unloaded or deleted.

Notes:

radio_button_unchecked

Does not fire when exiting Neovim with :qa or :q.