InterviewSolution
This section includes InterviewSolutions, each offering curated multiple-choice questions to sharpen your knowledge and support exam preparation. Choose a topic below to get started.
| 1. |
Flexbox - Bootstrap |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Answer» The main difference between Bootstrap 3 and Bootstrap 4 & 5 is that Bootstrap 5 now uses flexbox, instead of floats, to handle the layout. Bootstrap 5 provides us with classes to let us use flexbox easily.
In this bootstrap cheat sheet, you can find all the information you need while learning HTML and front-end development. Furthermore, it can be used as a reference when building a project using the popular HTML framework.
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 2. |
Spacing - Bootstrap |
|||||||||||||||||||||||||||||||||||||||||||||
|
Answer» Bootstrap includes a wide range of shorthand responsive margin, padding, and gap utility classes to modify an element’s appearance.
|
||||||||||||||||||||||||||||||||||||||||||||||
| 3. |
Sizing - Bootstrap |
||||||||||||
|
Answer» With width and height utilities, you can easily make an element as wide or tall as its parent.
|
|||||||||||||
| 4. |
Colors - Bootstrap |
||||||||||||||||||||||||||||||
|
Answer» Use a handful of colour utility classes to convey meaning through color.Supports styling links with hover states, too. Example:
|
|||||||||||||||||||||||||||||||
| 5. |
Display - Bootstrap |
|||||||||||||||||||||||||||
|
Answer» We can quickly Quickly and responsively toggle the display value of components and more with the help of display utilities.
|
||||||||||||||||||||||||||||
| 6. |
Border Utilities - Bootstrap |
||||||||||||||||||||||||
|
Answer» You can quickly style an element's border and border-radius by using border utilities. These are great for images, buttons, or any other element. Example:
|
|||||||||||||||||||||||||
| 7. |
Tables - Bootstrap |
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Answer» Using tables in bootstrap, you can aggregate a huge amount of data and present it in a clear, logical manner. You just need to add the base class .table, then extend with custom styles or modifier classes. Example: Basic Table bootstrap 4 The .table class is used to add basic styling (light padding and only horizontal dividers) to a table:
<html lang="en"> <head> <title>Bootstrap Example</title> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js"></script> </head> <body> <div class="container"> <h2>Basic Table bootstrap 4</h2> <p>The .table class adds basic styling (light padding and only horizontal dividers) to a table:</p> <table class="table"> <thead> <tr> <th>Firstname</th> <th>Lastname</th> <th>Email</th> </tr> </thead> <tbody> <tr> <td>Lavish </td> <td>malik</td> <td>lavishmalik28@gmail.com</td> </tr> <tr> <td>John</td> <td>dellinger</td> <td>jogndellinger01@gmail.com</td> </tr> </tbody> </table> </div> </body> </html>
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 8. |
Navbar - Bootstrap |
|||||||||||||||||||||||||||||||||
Answer»
Example: <nav class="navbar navbar-expand-lg navbar-light bg-light"><a class="navbar-brand" href="#">Navbar</a> <button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navbarSupportedContent" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation"> <span class="navbar-toggler-icon"></span> </button> <div class="collapse navbar-collapse" id="navbarSupportedContent"> <ul class="navbar-nav mr-auto"> <li class="nav-item active"> <a class="nav-link" href="#">Home <span class="sr-only">(current)</span></a> </li> <li class="nav-item"> <a class="nav-link" href="#">Bootstrap Link</a> </li> <li class="nav-item dropdown"> <a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> Dropdown </a> <div class="dropdown-menu" aria-labelledby="navbarDropdown"> <a class="dropdown-item" href="#">Action</a> <a class="dropdown-item" href="#">Another action</a> <div class="dropdown-divider"></div> <a class="dropdown-item" href="#">Something else here</a> </div> </li> <li class="nav-item"> <a class="nav-link disabled" href="#">Disabled</a> </li> </ul> <form class="form-inline my-2 my-lg-0"> <input class="form-control mr-sm-2" type="search" placeholder="Search" aria-label="Search"> <button class="btn btn-outline-success my-2 my-sm-0" type="submit">Search</button> </form> </div> </nav>
|
||||||||||||||||||||||||||||||||||
| 9. |
Jumbotron - Bootstrap |
|||
|
Answer» This component can increase the size of headings and add a lot of margin for landing page content. For using Jumbotron: simply create a container with the class of .jumbotron.
|
||||
| 10. |
Grid System - Bootstrap |
||||||||||||||||||||||||||||||||||||||||||
Answer»
|
|||||||||||||||||||||||||||||||||||||||||||
| 11. |
Forms - Bootstrap |
||||||||||||||||||||||||||||||||||||
|
Answer» A form is a common tool of HTML which is used to collect data from the user.Bootstrap allows us to style forms. Example: <form><div class="form-group"> <label for="exampleInputEmail1">Email address</label> <input type="email" class="form-control" id="exampleInputEmail1" aria-describedby="emailHelp" placeholder="Enter email"> <small id="emailHelp" class="form-text text-muted">We'll never share your email with anyone else.</small> </div> <div class="form-group"> <label for="exampleInputPassword1">Password</label> <input type="password" class="form-control" id="exampleInputPassword1" placeholder="Password"> </div> <div class="form-check"> <input type="checkbox" class="form-check-input" id="exampleCheck1"> <label class="form-check-label" for="exampleCheck1">Check me out</label> </div> <button type="submit" class="btn btn-primary">Submit</button> </form>
|
|||||||||||||||||||||||||||||||||||||
| 12. |
Dropdowns - Bootstrap |
||||||||||||||||||
|
Answer» Dropdowns are toggleable, contextual overlays that display lists of links and more. They allow the user to choose one value from a predefined list. Example: Dropdown button for bootstrap Bootstrap cheatsheet Bootstrap 5 cheatsheet Bootstrap 4 cheatsheet <div class="dropdown"> <button class="btn btn-secondary dropdown-toggle" type="button" id="dropdownMenuButton" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"> Dropdown button for bootstrap </button> <div class="dropdown-menu" aria-labelledby="dropdownMenuButton"> <a class="dropdown-item" href="#">Bootstrap cheatsheet</a> <a class="dropdown-item" href="#">Bootstrap 5 cheatsheet</a> <a class="dropdown-item" href="#">Bootstrap 4 cheatsheet</a> </div> </div>
|
|||||||||||||||||||
| 13. |
Collapse - Bootstrap |
||||||
|
Answer» With JavaScript plugins, you can change the visibility of content across your project with the help of collapse. Example: <!DOCTYPE html><html lang="en"> <head> <title>collapse in bootstrap</title> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet"> <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/js/bootstrap.bundle.min.js"></script> </head> <body> <div class="container mt-3"> <h2>collapse in bootstrap</h2> <p>Click on the button to toggle between showing and hiding content.</p> <button type="button" class="btn btn-primary" data-bs-toggle="collapse" data-bs-target="#demo">Simple collapsible</button> <div id="demo" class="collapse"> Learn bootstrap </div> </div> </body> </html>
|
|||||||
| 14. |
Carousel- Bootstrap |
|||||||||||||||
|
Answer» A slideshow component that cycles through elements - images or slides of text - like a carousel.
|
||||||||||||||||
| 15. |
Pagination - Bootstrap |
|||||||||||||||
|
Answer» Pagination helps to display the different page numbers of a website. With the help of paginators, we can jump to any page of the website.
|
||||||||||||||||
| 16. |
Cards - Bootstrap |
||||||||||||||||||||||||||||||||||||||||||
|
Answer» We have cards in Bootstrap that are simple containers that can hold images and descriptions. Below are some of the functions associated with a card.
|
|||||||||||||||||||||||||||||||||||||||||||
| 17. |
Badges - Bootstrap |
||||||||||||||||||||||||||||||
|
Answer» Bootstrap badges are used for adding additional information. Example: <!DOCTYPE html><html lang="en"> <head> <title>Bootstrap Example</title> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link href="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/css/bootstrap.min.css" rel="stylesheet"> <script src="https://cdn.jsdelivr.net/npm/bootstrap@5.1.3/dist/js/bootstrap.bundle.min.js"></script> </head> <body> <div class="container mt-3"> <h2>Badges</h2> <h1>Welcome to InterviewBit<span class="badge bg-secondary">New</span></h1> </div> </body> </html>
|
|||||||||||||||||||||||||||||||
| 18. |
Breadcrumb - Bootstrap |
|||
Answer»
|
||||
| 19. |
Buttons - Bootstrap |
||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
Answer» Responsive buttons can be built with the latest bootstrap 5. Example: Primary Secondary Success Danger Warning Info Light Dark Link
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 20. |
Alerts - Bootstrap |
|||||||||||||||||||||||||||||||||
Answer»
Example: <!DOCTYPE html><html lang="en"> <head> <title>Bootstrap Example</title> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1"> <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/css/bootstrap.min.css"> <script src="https://ajax.googleapis.com/ajax/libs/jquery/3.5.1/jquery.min.js"></script> <script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.4.1/js/bootstrap.min.js"></script> </head> <body> <div class="container"> <h2>Alerts</h2> <div class="alert alert-success"> <strong>Success! alert</strong> </div> <div class="alert alert-info"> <strong>Info! alert</strong> </div> <div class="alert alert-warning"> <strong>Warning! alert</strong> </div> <div class="alert alert-danger"> <strong>Danger! alert</strong> </div> </div> </body> </html>
|
||||||||||||||||||||||||||||||||||
| 21. |
Features of Bootstrap |
Answer»
|
|
| 22. |
Uses of Bootstrap |
Answer»
|
|
| 23. |
Bootstrap Skeleton |
|
Answer» <!DOCTYPE html> <html> <head> <title>Bootstrap 101 Template</title> <meta name="viewport" content="width=device-width, initial-scale=1.0"> <!-- Bootstrap --> <link href="css/bootstrap.min.css" rel="stylesheet"> </head> <body> <h1>Hello, world!</h1> <!-- jQuery (necessary for Bootstrap's JavaScript plugins) --> <script src="https://code.jquery.com/jquery.js"></script> <!-- Include all compiled plugins, or just specific files as needed --> <script src="js/bootstrap.min.js"></script> </body> </html> |
|