Adding a Navbar
Learn to add a navbar using Bootstrap to a Beego project
Designing a responsive navbar
In this lesson, we will add a custom navbar to our Beego web application. The custom navbar will provide navigation links and user-specific information. This lesson is optional because we’re just going to be beautifying the application.
We are going to create a navbar that looks like this:
The navbar shown above is the blue bar on the top that holds the links to the home page and all notes page (/notes
). It is also a placeholder for the “Sign Up” and “Login” links. If the user is logged in, it shows the email ID of the user and the “Logout” button.
The navbar changes based on the user’s logged-in status. If the user is logged in, we show the user’s email in the navbar.
To build the navbar, we will follow these steps: ...
Get hands-on with 1400+ tech skills courses.