Files included in the Bootstrap distribution
In order to get acquainted with the files inside the Bootstrap distribution, you need to download its source files. At the time of writing, Bootstrap 4 was still in Alpha, and its source files can be downloaded from http://v4-alpha.getbootstrap.com.
Bootstrap style sheets
Do not be alarmed by the amount of files inside the css
folder. This folder contains four .css
files and two .map
files. We only need to include the bootstrap.css
file in our project for the Bootstrap styles to be applied to our pages. The bootstrap.min.css
file is simply a minified version of the aforementioned file. The .map
files can be ignored for the project we'll be creating. These files are used as a type of debug symbol (similar to the .pdb
files in Visual Studio), which allows developers to live edit their preprocessor source files, something that is beyond the scope of this book.
Bootstrap JavaScript files
The js
folder contains two files. All the Bootstrap plugins are contained in the bootstrap.js
file. The bootstrap.min.js
file is simply a minified version of the aforementioned file. Before including the file in your project, make sure that you have a reference to the jQuery library because all Bootstrap plugins require jQuery.
Bootstrap fonts/icons
Bootstrap 3 uses Glyphicons to display various icons and glyphs in Bootstrap sites. Bootstrap 4 will no longer ship with glyphicons included, but you still have the option to include it manually or to include your own icons. The following two icon sets are good alternatives to Glyphicons:
- Font Awesome, available from http://fontawesome.io/
- GitHub's Octicons, available from https://octicons.github.com/
Bootstrap source files
Before you can get started with Bootstrap, you first need to download the Bootstrap source files. At the time of writing, Bootstrap 4 was at version 4 Alpha 3. You have a few choices when adding Bootstrap to you project. You can download the compiled CSS and JavaScript files or you can use a number of package managers to install the Bootstrap Sass source to your project.
In this chapter, you'll be using Bower to add the Bootstrap 4 source files to your project.
Note
For a complete list of Bootstrap 4 Alpha installation sources, visit http://v4-alpha.getbootstrap.com/getting-started/download/.