So sorry, I somehow missed that, I spent some time trying to find solutions but only found posts for login.
Thank You!
Edit: I still think that this kind of feature should definitely work without JavaScript as well. It would be really good to have a proper URL for this, even if it was behind a feature toggle. It doesn’t even have to trigger from GET, the page could just have a form on it with a button to log out.