Book Image

Learning Bootstrap 4 - Second Edition

By : Matt Lambert
Book Image

Learning Bootstrap 4 - Second Edition

By: Matt Lambert

Overview of this book

Bootstrap, the most popular front-end framework built to design elegant, powerful, and responsive interfaces for professional-level web pages has undergone a major overhaul. Bootstrap 4 introduces a wide range of new features that make front-end web design even simpler and exciting. In this gentle and comprehensive book, we'll teach you everything that you need to know to start building websites with Bootstrap 4 in a practical way. You'll learn about build tools such as Node, Grunt, and many others. You'll also discover the principles of mobile-first design in order to ensure your pages can fit any screen size and meet the responsive requirements. Learn to play with Bootstrap's grid system and base CSS to ensure your designs are robust and that your development process is speedy and efficient. Then, you'll find out how you can extend your current build with some cool JavaScript Plugins, and throw in some Sass to spice things up and customize your themes. This book will make sure you're geared up and ready to build amazingly beautiful and responsive websites in a jiffy.
Table of Contents (15 chapters)
Learning Bootstrap 4 - Second Edition
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
Free Chapter
1
Introducing Bootstrap 4

Adding columns to your layout


Before we jump into actually adding the columns, let's talk a little bit about the different column classes you have at your disposal with Bootstrap. In Bootstrap 3 there were four different column class widths to choose from: extra small, small, medium, and large. With Bootstrap 4, they have also introduced a new extra large column class. This is likely to allow for extra large monitors, like you would find on an iMac. Let's go over the fine points of each column class in Bootstrap 4.

Extra small

The smallest of the grid classes uses the naming pattern .col-xs-#, where -# is equal to a number from 1 to 12. Remember, in Bootstrap, your row must be divided into a number of columns that adds up to 12. A couple of examples of this would be .col-xs-6 or .col-xs-3. The extra small column class is for targeting mobile devices that have a max-width of 544 pixels.

Small

The small column class uses the syntax pattern .col-sm-#, and some examples of that would be .col-sm...