Professional Documents
Culture Documents
Web Application Development: Bootstrap Framework
Web Application Development: Bootstrap Framework
Web Application Development: Bootstrap Framework
Development
Bootstrap Framework
What is Bootstrap?
● Most Popular Front-End Framework
● Used for building responsive, mobile first websites and web applications
● HTML/CSS/Javascript
Why use Bootstrap?
● Increase development speed
● Assure responsiveness
● Prevent repetition between projects
● Add consistency
● Ensure cross browser compatibility
● Larger community
● Customizable
Bootstrap Grid System
● In order to create a layout, we use:
○ Container
○ Row
○ Columns (Upto 12)
Grid Breakpoints
Class Demo on Grids
● The use of container vs container-fluid
● Using columns with and without breakpoints and sizes
Buttons
● Buttons with different classes for different colors using classes btn and btn-
primary example.
● Outline buttons
Cards and Panels
Introduction
● To use Bootstrap you can use the CDN
● Download source files at:
○ https://getbootstrap.com/docs/5.0/getting-started/download/
○ Use CDN and include the needed links
Working with Navigation Bar
● The classes are:
○ Navbar
○ Navbar-expand (Check for breakpoints in the Website for different collapse
sizes).
○ Navbar-brand: For the logo in the navigation bar
● For the Menu, use a block (div) tag with collapse and nav-collapse
classes, the ul should contain the navbar-nav class, the list items
should have have nav-item class and for the links, the class
should be nav-link.
● Ms-auto class, sets the navigation link to the (far) right.
● You can add padding using (py class for padding bottom and top)
Navigation Bar
● The nav tag is used to display the navigation
○ <nav class="navbar navbar-expand-lg bg-dark navbar-dark py-3">
● The a link in the navigation bar uses navbar-brand
○ <a href="#" class="navbar-brand">SUZA Youthmappers</a>
● The link is contained within navbar-collapse and collapse classes
○ <div class="collapse navbar-collapse" id="navmenu">
○ <ul class="navbar-nav ms-auto">
○ <li class="nav-item">
○ <a href="" class="nav-link">About Us</a>
○ </li>
○ </ul>
○ </div>
Nav Bar Code
<nav class="navbar navbar-expand-lg bg-dark navbar-dark py-3">
<div class="container">
<a href="#" class="navbar-brand">SUZA Youthmappers</a>
<button
class="navbar-toggler"
type="button"
data-bs-toggle="collapse"
data-bs-target="#navmenu"
>
<span class="navbar-toggler-icon"></span>
</button>
https://www.youtube.com/watch?v=rQryOSyfXmI