Edit contents of front-end HTML file based on value from express-session

I am currently trying to build a login page for my web application using express-session. I have everything working as far as confirming a valid login.

Once a valid login is confirmed, I run the following code within the app.post() method.

request.session.loggedIn = true
request.session.username = data[0].account_user
response.redirect('/')

The redirect takes me back to the home page. How can I then now check the value of those variables, and edit what the user sees on the front-end?

For example if nobody is logged in, I want it to display login/signup buttons. If they are logged in, I want to hide those and display their username.