Bootstrap cdn complete css

Скачать

Загрузите готовый к использованию скомпилированный код для Bootstrap v5.0.1, чтобы легко вставить его в свой проект, который включает:

  • Скомпилированные и минифицированные пакеты CSS (см. сравнение файлов CSS)
  • Скомпилированные и минимизированные плагины JavaScript

Это не включает документацию, исходные файлы или любые дополнительные зависимости JavaScript, такие как Popper.js.

Исходные файлы

Скомпилируйте Bootstrap с вашим собственным конвейером ресурсов, загрузив наши исходные файлы Sass, JavaScript и документации. Для этого варианта требуются дополнительные инструменты:

  • Компилятор Sass (поддерживается Libsass или Ruby Sass) для компиляции вашего CSS.
  • Автопрефиксатор для префикса поставщика CSS

Если вам потребуются инструменты сборки , они включены для разработки Bootstrap и документации к нему, но, скорее всего, они не подходят для ваших собственных целей.

Примеры

Если вы хотите скачать и изучить наши примеры, вы можете взять уже построенные примеры:

Bootstrap CDN

Пропустите загрузку с помощью BootstrapCDN, чтобы предоставить вашему проекту кешированную версию скомпилированных CSS и JS Bootstrap.

link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.1/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-+0n0xVW2eSR5OomGNYDnhzAbDsOXxcvSN1TPprVMTNDbiYZCxYbOOl7+AMvyTG2x" crossorigin="anonymous"> script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.1/dist/js/bootstrap.bundle.min.js" integrity="sha384-gtEjrD/SeCtmISkJkNUaaKMoLD0//ElJ19smozuHV6z3Iehds+3Ulb9Bn9Plx0x4" crossorigin="anonymous">script> 

Если вы используете наш скомпилированный JavaScript, не забудьте включить Popper.js, желательно через CDN, перед нашим JS.

script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.9.2/dist/umd/popper.min.js" integrity="sha384-IQsoLXl5PILFhosVNubq5LC7Qb9DXgDA9i+tQ8Zj3iwWAwPtgFTxbJ8NT4GN1R8p" crossorigin="anonymous">script> script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.1/dist/js/bootstrap.min.js" integrity="sha384-Atwg2Pkwv9vp0ygtn1JAojH0nYbwNJLPhwyoVbhoPwBhjQPR5VtM2+xf0Uwh9KtT" crossorigin="anonymous">script> 

Менеджеры пакетов

Загрузите исходные файлы Bootstrap практически в любой проект с помощью некоторых из самых популярных менеджеров пакетов. Независимо от менеджера пакетов, Bootstrap потребует компилятор Sass и Autoprefixer для настройки, соответствующей нашим официальным скомпилированным версиям.

npm

Установите Bootstrap в приложения на базе Node.js с пакетом npm:

npm install bootstrap@next

const bootstrap = require(‘bootstrap’) or import bootstrap from ‘bootstrap’ загрузит все плагины Bootstrap в bootstrap объект. Сам bootstrap модуль экспортирует все наши плагины. Вы можете вручную загрузить плагины Bootstrap по отдельности, загрузив /js/dist/*.js файлы в каталог верхнего уровня пакета.

Bootstrap package.json содержит некоторые дополнительные метаданные под следующими ключами:

  • sass — путь к основному исходному файлу Sass Bootstrap
  • style — путь к неминифицированному CSS Bootstrap, который был предварительно скомпилирован с использованием настроек по умолчанию (без настройки)

yarn

Установите Bootstrap в свои приложения на базе Node.js с пакетом yarn:

RubyGems

Установите Bootstrap в свои приложения Ruby с помощью Bundler ( рекомендуется ) и RubyGems , добавив следующую строку в ваш Gemfile :

В качестве альтернативы, если вы не используете Bundler, вы можете установить гем, выполнив эту команду:

gem install bootstrap -v 5.0.1

Смотри документацию для получения дополнительной информации.

Composer

Вы также можете установить Sass и JavaScript для Bootstrap и управлять ими с помощью Composer:

composer require twbs/bootstrap:5.0.1

NuGet

Если вы разрабатываете в .NET, вы также можете установить CSS или Sass и JavaScript для Bootstrap и управлять ими с помощью NuGet:

Install-Package bootstrap.sass

Разработан и построен с любовью к миру, командой Bootstrap и помощью наших участников.

В настоящее время v5.0.0-alpha1. Код под лицензией MIT, документы CC BY 3.0.

Недорогие домены, регистрация + продление: nadomen.ru

Перевод документации: Голягин Алексей

Источник

Introduction

Get started with Bootstrap, the world’s most popular framework for building responsive, mobile-first sites, with jsDelivr and a template starter page.

Quick start

Looking to quickly add Bootstrap to your project? Use jsDelivr, a free open source CDN. Using a package manager or need to download the source files? Head to the downloads page.

CSS

Copy-paste the stylesheet into your before all other stylesheets to load our CSS.

link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous"> 

JS

Many of our components require the use of JavaScript to function. Specifically, they require our own JavaScript plugins and Popper. Place one of the following s near the end of your pages, right before the closing tag, to enable them.

Bundle

Include every Bootstrap JavaScript plugin and dependency with one of our two bundles. Both bootstrap.bundle.js and bootstrap.bundle.min.js include Popper for our tooltips and popovers. For more information about what’s included in Bootstrap, please see our contents section.

script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js" integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" crossorigin="anonymous">script> 

Separate

If you decide to go with the separate scripts solution, Popper must come first (if you’re using tooltips or popovers), and then our JavaScript plugins.

script src="https://cdn.jsdelivr.net/npm/@popperjs/core@2.9.2/dist/umd/popper.min.js" integrity="sha384-IQsoLXl5PILFhosVNubq5LC7Qb9DXgDA9i+tQ8Zj3iwWAwPtgFTxbJ8NT4GN1R8p" crossorigin="anonymous">script> script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.min.js" integrity="sha384-cVKIPhGWiC2Al4u+LWgxfKTRIcfu0JTxR+EQDz/bgldoEyl4H0zUF0QKbrJ0EcQF" crossorigin="anonymous">script> 

Modules

Components

Curious which components explicitly require our JavaScript and Popper? Click the show components link below. If you’re at all unsure about the general page structure, keep reading for an example page template.

  • Alerts for dismissing
  • Buttons for toggling states and checkbox/radio functionality
  • Carousel for all slide behaviors, controls, and indicators
  • Collapse for toggling visibility of content
  • Dropdowns for displaying and positioning (also requires Popper)
  • Modals for displaying, positioning, and scroll behavior
  • Navbar for extending our Collapse plugin to implement responsive behavior
  • Toasts for displaying and dismissing
  • Tooltips and popovers for displaying and positioning (also requires Popper)
  • Scrollspy for scroll behavior and navigation updates

Starter template

Be sure to have your pages set up with the latest design and development standards. That means using an HTML5 doctype and including a viewport meta tag for proper responsive behaviors. Put it all together and your pages should look like this:

 html lang="en"> head> meta charset="utf-8"> meta name="viewport" content="width=device-width, initial-scale=1"> link href="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/css/bootstrap.min.css" rel="stylesheet" integrity="sha384-EVSTQN3/azprG1Anm3QDgpJLIm9Nao0Yz1ztcQTwFspd3yD65VohhpuuCOmLASjC" crossorigin="anonymous"> title>Hello, world!title> head> body> h1>Hello, world!h1>  script src="https://cdn.jsdelivr.net/npm/bootstrap@5.0.2/dist/js/bootstrap.bundle.min.js" integrity="sha384-MrcW6ZMFYlzcLA8Nl+NtUVF0sA7MsXsP1UyJoMp4YLEuNSfAP+JcXn/tWtIaxVXM" crossorigin="anonymous">script>      --> body> html> 

For next steps, visit the Layout docs or our official examples to start laying out your site’s content and components.

Important globals

Bootstrap employs a handful of important global styles and settings that you’ll need to be aware of when using it, all of which are almost exclusively geared towards the normalization of cross browser styles. Let’s dive in.

HTML5 doctype

Bootstrap requires the use of the HTML5 doctype. Without it, you’ll see some funky incomplete styling, but including it shouldn’t cause any considerable hiccups.

Responsive meta tag

Bootstrap is developed mobile first, a strategy in which we optimize code for mobile devices first and then scale up components as necessary using CSS media queries. To ensure proper rendering and touch zooming for all devices, add the responsive viewport meta tag to your .

meta name="viewport" content="width=device-width, initial-scale=1"> 

You can see an example of this in action in the starter template.

Box-sizing

For more straightforward sizing in CSS, we switch the global box-sizing value from content-box to border-box . This ensures padding does not affect the final computed width of an element, but it can cause problems with some third-party software like Google Maps and Google Custom Search Engine.

On the rare occasion you need to override it, use something like the following:

.selector-for-some-widget  box-sizing: content-box; > 

With the above snippet, nested elements—including generated content via ::before and ::after —will all inherit the specified box-sizing for that .selector-for-some-widget .

Reboot

For improved cross-browser rendering, we use Reboot to correct inconsistencies across browsers and devices while providing slightly more opinionated resets to common HTML elements.

Community

Stay up to date on the development of Bootstrap and reach out to the community with these helpful resources.

  • Read and subscribe to The Official Bootstrap Blog.
  • Chat with fellow Bootstrappers in IRC. On the irc.libera.chat server, in the #bootstrap channel.
  • Implementation help may be found at Stack Overflow (tagged bootstrap-5 ).
  • Developers should use the keyword bootstrap on packages that modify or add to the functionality of Bootstrap when distributing through npm or similar delivery mechanisms for maximum discoverability.

You can also follow @getbootstrap on Twitter for the latest gossip and awesome music videos.

  • Designed and built with all the love in the world by the Bootstrap team with the help of our contributors.
  • Code licensed MIT, docs CC BY 3.0.
  • Currently v5.0.2.
  • Analytics by Fathom.

Источник

Читайте также:  Which css property controls the text size
Оцените статью