Monday, August 12, 2019

How to custom Navbar bootstrap 4 Responsive

Hello everyone today I will show you How to custom Navbar bootstrap 4 Responsive a simple way, there are now many websites are using navbar bootstrap 4 so therefore I would write the following code so that people can use the navbar reponsive a reasonable way for website.
Navbar bootstrap 4 Responsive

CSS

.bg-custom-1 {
  background-color: #85144b;
}
.bg-custom-2 {
background-image: linear-gradient(15deg, #13547a 0%, #80d0c7 100%);
}
.bg-company-red {
    background-color: darkred !important;
}

HTML
<nav class="navbar navbar-dark bg-company-red navbar-expand-sm">
  <a class="navbar-brand" href="https://tienanhvn.blogspot.com">
    TienAnhvn
  </a>
  <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbar-list-2" aria-controls="navbarNav" aria-expanded="false" aria-label="Toggle navigation">
    <span class="navbar-toggler-icon"></span>
  </button>
  <div class="collapse navbar-collapse"id="navbar-list-2">
    <ul class="navbar-nav">
      <li class="nav-item active">
        <a class="nav-link" href="#">Home</a>
      </li>
      <li class="nav-item">
        <a class="nav-link" href="#">Bootstrap</a>
      </li>
      <li class="nav-item">
        <a class="nav-link" href="#">Blog</a>
      </li>
    </ul>
  </div>
</nav> 
 Result
How to custom Navbar bootstrap 4 Responsive

No comments:

Post a Comment