One reason to hide it is for caching. For example on your home page, if you're logged out show login button. If logged in show logout button. This kills the cache.
How do I force a website to log out?
To do this, hit Ctrl + Shift + Del. This should open the Clear Browsing Data dialog box. From the pop-up menu, select All time and check Cookies and other site data only. Click on clear data and this should log you out of all websites conveniently when you close the browser window.
Is it important to log out of websites?
Logging out of a computer is very important because there are risk with not logging out. One of the factor is using a public computer, this is where anyone can use a public computer when someone is still logged in to an account and can mess with that person's work.