{"id":312,"date":"2017-10-22T12:34:30","date_gmt":"2017-10-22T07:04:30","guid":{"rendered":"http:\/\/blog.openwebsolutions.in\/?p=312"},"modified":"2017-10-22T15:17:46","modified_gmt":"2017-10-22T09:47:46","slug":"whats-new-in-bootstrap-4","status":"publish","type":"post","link":"https:\/\/openwebsolutions.in\/blog\/whats-new-in-bootstrap-4\/","title":{"rendered":"What\u2019s new in Bootstrap 4"},"content":{"rendered":"<p>&nbsp;<\/p>\n<p>In this blog I am going to explain about new Bootstrap version that is <a href=\"http:\/\/getbootstrap.com\/\"><em><strong>Bootstrap v4.0.0-beta.2.<\/strong><\/em><\/a><\/p>\n<p>At first I am going to tell what is Bootstrap and what for this is used. Bootstrap is basically a css framework i.e. front-end component library which build responsive, mobile-first projects on the web.<\/p>\n<p>It is also an open source toolkit for developing with HTML, CSS, and JS to build entire app with our Sass variables and mixins, responsive grid system, extensive prebuilt components, and powerful plugins built on jQuery.<\/p>\n<p>The new Bootstrap beta version is almost complete version for usage and \u00a0it\u2019s components that need Popper.js as dependency.<\/p>\n<p><img loading=\"lazy\" class=\"alignnone size-full wp-image-313\" src=\"http:\/\/blog.openwebsolutions.in\/wp-content\/uploads\/2017\/10\/img1.png\" alt=\"image one\" width=\"760\" height=\"267\" srcset=\"https:\/\/openwebsolutions.in\/blog\/wp-content\/uploads\/2017\/10\/img1.png 760w, https:\/\/openwebsolutions.in\/blog\/wp-content\/uploads\/2017\/10\/img1-300x105.png 300w\" sizes=\"(max-width: 760px) 100vw, 760px\" \/><\/p>\n<p>It is required as because<\/p>\n<ul>\n<li>Tooltips rely on the 3rd party library Popper.js for positioning.<\/li>\n<li>Popovers rely on the 3rd party library Popper.js for positioning.<\/li>\n<li>Dropdowns are built on a third party library, Popper.js, which provides dynamic positioning and viewport detection.<\/li>\n<\/ul>\n<p>So these are the Bootstrap 4 components that need Popper.js.<\/p>\n<p>Though Popper.js is stated as required for Bootstrap 4, and Bootstrap 4 JS logs an error if it can&#8217;t find Popper,\u00a0<strong>you can still use Bootstrap 4 JS without Popper, if you don&#8217;t need tooltips, popovers nor dropdowns and Bootstrap modals also require Popper.js.<\/strong><\/p>\n<p>&nbsp;<\/p>\n<h4><strong><a href=\"http:\/\/getbootstrap.com\/docs\/4.0\/layout\/grid\/\"><em>Grid System<\/em><\/a><\/strong><\/h4>\n<p>Bootstrap\u2019s grid system uses a series of containers, rows, and columns to layout and align content. It\u2019s built with\u00a0<a href=\"https:\/\/developer.mozilla.org\/en-US\/docs\/Web\/CSS\/CSS_Flexible_Box_Layout\/Using_CSS_flexible_boxes\">flexbox<\/a>\u00a0and is fully responsive. Below is an example and an in-depth look at how the grid comes together.<\/p>\n<p><img loading=\"lazy\" class=\"alignnone wp-image-314\" src=\"http:\/\/blog.openwebsolutions.in\/wp-content\/uploads\/2017\/10\/img2.png\" alt=\"image 2\" width=\"621\" height=\"341\" \/><\/p>\n<p style=\"margin: 0mm;margin-bottom: .0001pt;vertical-align: baseline\"><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\">The above example creates three equal-width columns on small, medium, large, and extra large devices using our predefined grid classes. Those columns are centered in the page with the parent\u00a0<\/span><code style=\"padding: 0.2rem 0.4rem\"><span style=\"font-size: 11.0pt;font-family: Consolas;color: #bd4147;background: #F8F9FA\">.container<\/span><\/code><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\"><span style=\"float: none\">.<\/span> This is called flexbox design.<\/span><\/p>\n<p style=\"margin: 0mm;margin-bottom: .0001pt;vertical-align: baseline\"><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\">\u00a0<\/span><\/p>\n<p style=\"margin-top: 0mm\"><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\">While Bootstrap uses\u00a0<\/span><code style=\"padding: 0.2rem 0.4rem\"><span style=\"font-size: 11.0pt;font-family: Consolas;color: #bd4147;background: #F8F9FA\">em<\/span><\/code><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\">s or\u00a0<\/span><code style=\"padding: 0.2rem 0.4rem\"><span style=\"font-size: 11.0pt;font-family: Consolas;color: #bd4147;background: #F8F9FA\">rem<\/span><\/code><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\">s for defining most sizes,\u00a0<\/span><code style=\"padding: 0.2rem 0.4rem\"><span style=\"font-size: 11.0pt;font-family: Consolas;color: #bd4147;background: #F8F9FA\">px<\/span><\/code><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\">s are used for grid breakpoints and container widths. This is because the viewport width is in pixels and does not change with the font size.<\/span><\/p>\n<p style=\"margin-top: 0mm;margin-bottom: 1rem;max-width: 80%\"><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\">See how aspects of the Bootstrap grid system work across multiple devices with a handy table.<\/span><\/p>\n<p style=\"margin-top: 0mm;background: white;margin-bottom: 1rem;max-width: 80%\"><img loading=\"lazy\" class=\"alignnone wp-image-315\" src=\"http:\/\/blog.openwebsolutions.in\/wp-content\/uploads\/2017\/10\/img3.png\" alt=\"image 3\" width=\"621\" height=\"315\" \/><\/p>\n<p style=\"margin-top: 0mm\"><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\">Here \u2013xs- class is deleted and new \u2013xl- class has been added for extra large screens.<\/span><\/p>\n<p><strong>Auto width with columns with equal width<\/strong><\/p>\n<p style=\"margin: 0mm;margin-bottom: .0001pt;vertical-align: baseline\"><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\">For example, here are two grid layouts that apply to every device and viewport, from\u00a0<\/span><code style=\"padding: 0.2rem 0.4rem\"><span style=\"font-size: 11.0pt;font-family: Consolas;color: #bd4147;background: #F8F9FA\">xs<\/span><\/code><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529;background: white\"><span style=\"float: none\">to\u00a0<\/span><\/span><code style=\"padding: 0.2rem 0.4rem\"><span style=\"font-size: 11.0pt;font-family: Consolas;color: #bd4147;background: #F8F9FA\">xl<\/span><\/code><span style=\"font-family: 'Segoe UI','sans-serif';color: #212529\"><span style=\"float: none\">. Add any number of unit-less classes for each breakpoint you need and every column will be the same width.<\/span> <\/span><\/p>\n<p style=\"margin: 0mm;margin-bottom: .0001pt;background: white;vertical-align: baseline\"><img loading=\"lazy\" class=\"alignnone size-full wp-image-319\" src=\"http:\/\/blog.openwebsolutions.in\/wp-content\/uploads\/2017\/10\/img4.png\" alt=\"image 4\" width=\"789\" height=\"664\" srcset=\"https:\/\/openwebsolutions.in\/blog\/wp-content\/uploads\/2017\/10\/img4.png 789w, https:\/\/openwebsolutions.in\/blog\/wp-content\/uploads\/2017\/10\/img4-300x252.png 300w, https:\/\/openwebsolutions.in\/blog\/wp-content\/uploads\/2017\/10\/img4-768x646.png 768w\" sizes=\"(max-width: 789px) 100vw, 789px\" \/><\/p>\n<h4><\/h4>\n<p>&nbsp;<\/p>\n<h4><a href=\"https:\/\/getbootstrap.com\/docs\/4.0\/components\/card\/\"><em><strong>Cards<\/strong><\/em><\/a><\/h4>\n<p>&nbsp;<\/p>\n<p>Cards\u00a0replace Bootstrap 3&#8217;s old\u00a0panels\u00a0and\u00a0wells. Cards are defined as\u00a0<em>a flexible and extensible content container. It includes options for headers and footers, a wide variety of content, contextual background colors, and powerful display options.<\/em><\/p>\n<p>They&#8217;re essentially individual content blocks with a ton of out-of-the-box options.<\/p>\n<p>The big thing to take away here is you get a ton of new component options to basically build these little card blocks however you want.<\/p>\n<p>This works both with Flexbox and the default grid mode. If you&#8217;re using Flex Box, the cards are built using Flex Box properties. If you&#8217;re using the default grid, they&#8217;re actually using a CSS trick to avoid the need for JS. The container uses\u00a0display: table;\u00a0and each &#8220;card&#8221; is\u00a0display: table-cell;\u00a0making it have table properties (aka, equal column heights).<\/p>\n<p>&nbsp;<\/p>\n<h4><a href=\"https:\/\/getbootstrap.com\/docs\/4.0\/content\/reboot\/\"><em><strong>New Reset Component called Reboot.css<\/strong><\/em><\/a><\/h4>\n<p>&nbsp;<\/p>\n<p>Previously, Bootstrap used\u00a0Normalize.css\u00a0as its CSS reset. Normalize is awesome and well-respected. With Bootstrap 4, they actually just take normalize.css, and add some Bootstrap things to it.<\/p>\n<p>In layman&#8217;s terms, they combined their reset and base styles into a single file. This is useful because eventually you could essentially use just\u00a0reboot.css\u00a0on it&#8217;s own.<\/p>\n<p>&nbsp;<\/p>\n<h4 style=\"margin: 0mm;margin-bottom: .0001pt\"><a href=\"https:\/\/getbootstrap.com\/docs\/4.0\/getting-started\/theming\/#sass\"><em><strong><span style=\"font-family: Helvetica, sans-serif;color: #363636\"><span style=\"color: #222222;text-decoration: none\">Sass Variables for Customizing<\/span><\/span><\/strong><\/em><\/a><\/h4>\n<p>&nbsp;<\/p>\n<p>Everything with Bootstrap 4 is about customizing &#8211; maybe more than any other version before. They&#8217;ve consolidated all the variable options to a single file where you can compile your Sass on the fly and with little effort. This used be all previously done in a separate style sheet.<\/p>\n<p>There&#8217;s also a bunch of brand new customization options. They may streamline the process further to a different file.<\/p>\n<p>You can custom things like:<\/p>\n<ul>\n<li>Colors<\/li>\n<li>Options (Flex Box, transitions, rounded, shadows, etc.)<\/li>\n<li>Spacing<\/li>\n<li>Body (defaults)<\/li>\n<li>Link Styles<\/li>\n<li>Grid Breakpoints<\/li>\n<li>Grid Containers<\/li>\n<li>Grid Columns<\/li>\n<li>Typography<\/li>\n<li>Components<\/li>\n<li>Tables<\/li>\n<li>And more&#8230;<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<h4 style=\"margin: 0mm;margin-bottom: .0001pt\"><a href=\"https:\/\/getbootstrap.com\/docs\/4.0\/getting-started\/browsers-devices\/#supported-browsers\"><em><strong><span style=\"font-family: Helvetica, sans-serif;color: #363636\"><span style=\"color: #222222;text-decoration: none\">Dropped IE8 Support<\/span><\/span><\/strong><\/em><\/a><\/h4>\n<p>&nbsp;<\/p>\n<p>IE8 support was dropped. Dropping support for IE8 means we can take advantage of the best parts of CSS without being held back with CSS hacks or fallbacks. It also means that the maintainers can focus on new technologies and pushing forward.<\/p>\n<p>It&#8217;s currently unclear if there will be a partial support with a\u00a0HTML5 shiv\u00a0and\u00a0respond.js\u00a0or not. It seems though that if you need Internet Explorer 8 support, you&#8217;ll have to stick to using Bootstrap 3.<\/p>\n<p>&nbsp;<\/p>\n<h4 style=\"margin: 0mm;margin-bottom: .0001pt\"><a href=\"https:\/\/getbootstrap.com\/docs\/4.0\/content\/tables\/\"><em><strong><span style=\"font-family: Helvetica, sans-serif;color: #363636\"><span style=\"color: #222222;text-decoration: none\">Inverse Tables<\/span><\/span><\/strong><\/em><\/a><\/h4>\n<p>&nbsp;<\/p>\n<p>Tables now have an added\u00a0table-inverse\u00a0class for having another variation of a table. It&#8217;s definitely a nice to have.<\/p>\n<p>&nbsp;<\/p>\n<h4 style=\"margin: 0mm;margin-bottom: .0001pt\"><a href=\"https:\/\/getbootstrap.com\/docs\/4.0\/components\/buttons\/\"><em><strong><span style=\"font-family: Helvetica, sans-serif;color: #363636\">New <span style=\"color: #222222;text-decoration: none\">Outline Buttons<\/span><\/span><\/strong><\/em><\/a><\/h4>\n<p>&nbsp;<\/p>\n<p>Bootstrap 4 has added some new button styles with &#8220;Outline Buttons&#8221;. Outline Buttons appear hollow or are simply inverses of a regular button.<\/p>\n<p>The classes for them are:<\/p>\n<p><em>Primary<\/em><\/p>\n<p><em>Secondary<\/em><\/p>\n<p><em>Success<\/em><\/p>\n<p><em>Warning<\/em><\/p>\n<p><em>Danger<\/em><\/p>\n<p>&nbsp;<\/p>\n<h4><em><strong>Glyphicons are dropped<\/strong><\/em><\/h4>\n<p>&nbsp;<\/p>\n<p>Bootstrap 4 also dropped Glyphicon support. And recommended for using\u00a0<a href=\"https:\/\/fortawesome.github.io\/Font-Awesome\/\">FontAwesome<\/a><\/p>\n<p>&nbsp;<\/p>\n<h4><a href=\"https:\/\/getbootstrap.com\/docs\/4.0\/utilities\/borders\/\"><em><strong>Introduces new Spacing Utility Classes<\/strong><\/em><\/a><\/h4>\n<p>&nbsp;<\/p>\n<p>Another cool feature that was added is spacing utility classes. Spacing utility classes allow you to quickly add spacing in any direction via\u00a0margin\u00a0or\u00a0padding\u00a0using a utility class.<\/p>\n<p>For\u00a0<strong>Margin or Padding<\/strong> \u00a0use:<\/p>\n<ul>\n<li>&#8220;m&#8221; for margin<\/li>\n<li>&#8220;p&#8221; for padding<\/li>\n<\/ul>\n<p>For\u00a0<strong>direction<\/strong>, you can use:<\/p>\n<ul>\n<li>&#8220;a&#8221; for all<\/li>\n<li>&#8220;t&#8221; for top<\/li>\n<li>&#8220;r&#8221; for right<\/li>\n<li>&#8220;l&#8221; for left<\/li>\n<li>&#8220;x&#8221; for left and right<\/li>\n<li>&#8220;y&#8221; for top and bottom<\/li>\n<\/ul>\n<p>For\u00a0<strong>sizes<\/strong>, you can use:<\/p>\n<ul>\n<li>&#8220;0&#8221; for zero<\/li>\n<li>Leave Blank for default<\/li>\n<li>&#8220;auto&#8221; for Auto<\/li>\n<li>&#8220;md&#8221; for Medium<\/li>\n<li>&#8220;lg&#8221; for Large<\/li>\n<\/ul>\n<p><strong>Example :<\/strong><\/p>\n<p><em>&lt;div class=&#8221;w-100&#8243;&gt;&lt;\/div&gt;<\/em> = The div width is 100%<\/p>\n<p><em>&lt;div class=\u201dmr-3\u201d&gt;&lt;\/div&gt;<\/em> =\u00a0 margin right is 1 rem i.e. 16px<\/p>\n<p><em>&lt;div class=\u201dmt-3\u201d&gt;&lt;\/div&gt;<\/em> =\u00a0 margin top is 0<\/p>\n<p><em>&lt;div class=\u201dbg-light\u201d&gt;&lt;\/div&gt;<\/em> =\u00a0 Backgrounf color is light grey<\/p>\n<p>And much more..<\/p>\n<p>&nbsp;<\/p>\n<p>You can check and explore the whole Bootstrap docs for more on <a href=\"http:\/\/getbootstrap.com\/\">http:\/\/getbootstrap.com\/<\/a><\/p>\n<p>Please share if you like it!<\/p>\n<p>Follow me on\u00a0<a href=\"https:\/\/www.linkedin.com\/in\/preetam-mallick-84321254\/\"><em><strong>LinkedIn<\/strong><\/em><\/a><\/p>\n","protected":false},"excerpt":{"rendered":"<p>&nbsp; In this blog I am going to explain about new Bootstrap version that is Bootstrap v4.0.0-beta.2. At first I am going to tell what is Bootstrap and what for this is used. Bootstrap is basically a css framework i.e. front-end component library which build responsive, mobile-first projects on the web. It is also an [&hellip;]<\/p>\n","protected":false},"author":10,"featured_media":316,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":[],"categories":[3,5],"tags":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v14.8.1 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>What\u2019s new in Bootstrap 4 - Openweb Solutions Blog<\/title>\n<meta name=\"robots\" content=\"index, follow\" \/>\n<meta name=\"googlebot\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<meta name=\"bingbot\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/openwebsolutions.in\/blog\/whats-new-in-bootstrap-4\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"What\u2019s new in Bootstrap 4 - Openweb Solutions Blog\" \/>\n<meta property=\"og:description\" content=\"&nbsp; In this blog I am going to explain about new Bootstrap version that is Bootstrap v4.0.0-beta.2. At first I am going to tell what is Bootstrap and what for this is used. Bootstrap is basically a css framework i.e. front-end component library which build responsive, mobile-first projects on the web. It is also an [&hellip;]\" \/>\n<meta property=\"og:url\" content=\"https:\/\/openwebsolutions.in\/blog\/whats-new-in-bootstrap-4\/\" \/>\n<meta property=\"og:site_name\" content=\"Openweb Solutions Blog\" \/>\n<meta property=\"article:published_time\" content=\"2017-10-22T07:04:30+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2017-10-22T09:47:46+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/openwebsolutions.in\/blog\/wp-content\/uploads\/2017\/10\/banner-bootstrap.jpg\" \/>\n\t<meta property=\"og:image:width\" content=\"1024\" \/>\n\t<meta property=\"og:image:height\" content=\"497\" \/>\n<meta name=\"twitter:card\" content=\"summary\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"WebSite\",\"@id\":\"https:\/\/openwebsolutions.in\/blog\/#website\",\"url\":\"https:\/\/openwebsolutions.in\/blog\/\",\"name\":\"Openweb Solutions Blog\",\"description\":\"Transforming ideas into reality\",\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":\"https:\/\/openwebsolutions.in\/blog\/?s={search_term_string}\",\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/openwebsolutions.in\/blog\/whats-new-in-bootstrap-4\/#primaryimage\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/openwebsolutions.in\/blog\/wp-content\/uploads\/2017\/10\/banner-bootstrap.jpg\",\"width\":1024,\"height\":497,\"caption\":\"all new bootstrap banner\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/openwebsolutions.in\/blog\/whats-new-in-bootstrap-4\/#webpage\",\"url\":\"https:\/\/openwebsolutions.in\/blog\/whats-new-in-bootstrap-4\/\",\"name\":\"What\\u2019s new in Bootstrap 4 - Openweb Solutions Blog\",\"isPartOf\":{\"@id\":\"https:\/\/openwebsolutions.in\/blog\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/openwebsolutions.in\/blog\/whats-new-in-bootstrap-4\/#primaryimage\"},\"datePublished\":\"2017-10-22T07:04:30+00:00\",\"dateModified\":\"2017-10-22T09:47:46+00:00\",\"author\":{\"@id\":\"https:\/\/openwebsolutions.in\/blog\/#\/schema\/person\/615090f954d8460cf6186cf920b47398\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/openwebsolutions.in\/blog\/whats-new-in-bootstrap-4\/\"]}]},{\"@type\":\"Person\",\"@id\":\"https:\/\/openwebsolutions.in\/blog\/#\/schema\/person\/615090f954d8460cf6186cf920b47398\",\"name\":\"Preetam Mallick\",\"image\":{\"@type\":\"ImageObject\",\"@id\":\"https:\/\/openwebsolutions.in\/blog\/#personlogo\",\"inLanguage\":\"en-US\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/ed836329485e177373e4ff5323b6670a?s=96&r=g\",\"caption\":\"Preetam Mallick\"},\"description\":\"Frontend developer at Openweb Solutions\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","_links":{"self":[{"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/posts\/312"}],"collection":[{"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/users\/10"}],"replies":[{"embeddable":true,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/comments?post=312"}],"version-history":[{"count":16,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/posts\/312\/revisions"}],"predecessor-version":[{"id":333,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/posts\/312\/revisions\/333"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/media\/316"}],"wp:attachment":[{"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/media?parent=312"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/categories?post=312"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/openwebsolutions.in\/blog\/wp-json\/wp\/v2\/tags?post=312"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}