in English

Ka telesarize

Bootstrap telesarse walasa ka CSS ni JavaScript lajɛlenw sɔrɔ, source code, walima k’a don i ka pake ɲɛmɔgɔw la minnu ka di i ye i n’a fɔ npm, RubyGems ani dɔ wɛrɛw.

CSS ni JS labɛnna

Bootstrap v4.5.3 ka code compilé labɛnnenw telesarse walasa ka don nɔgɔya la i ka poroze kɔnɔ, o min kɔnɔ:

  • CSS bundlew lajɛlenw ni u fitininw (aw ye CSS files comparison lajɛ ) .
  • JavaScript fɛnɲɛnɛmaw lajɛlenw ani u fitininw

O tɛ sɛbɛnniw, source files, walima JavaScript dependencies (jQuery ani Popper.js) dɔw ye minnu bɛ se ka kɛ.

Ka telesarize

Source files (Filɛriw sɔrɔyɔrɔ).

Bootstrap labɛn ni i yɛrɛ ka nafolo pipeline ye i kɛtɔ ka an ka source Sass, JavaScript ani documentation files telesarse. Nin sugandi in bɛ baarakɛminɛn wɛrɛw de wajibiya:

  • Sass compiler (Libsass walima Ruby Sass bɛ dɛmɛ) ka ɲɛsin i ka CSS labɛnni ma.
  • Autoprefixer ka ɲɛsin CSS feerekɛlaw ka ɲɛfɔlisenw ma

Ni i ka kan ka build tools ɲini , u bɛ sɔrɔ Bootstrap n’a docs yiriwali kama, nka a ka c’a la u tɛ bɛn i yɛrɛ ka kuntilenna ma.

Télécharger source

Misaliw

N’i ​​b’a fɛ k’an ka misaliw telesarse ani k’u sɛgɛsɛgɛ , i bɛ se ka misali jɔlenw minɛ kaban:

Misaliw telesarse

jsDelivr ye

Tɛmɛn telesarseli kan ni jsDelivr ye walasa ka Bootstrap ka CSS ni JS lajɛlenw ka caché version lase i ka poroze ma.

<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/[email protected]/dist/css/bootstrap.min.css" integrity="sha384-TX8t27EcRE3e/ihU7zmQxVncDAy5uIKz4rEkgIXeMed4M0jlfIDPvg6uqKI2xXr2" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.bundle.min.js" integrity="sha384-ho+j7jyWK8fNQe+A12Hb8AhRq26LrZ/JpcUGGOn+Y7RsweNrtN/tE3MoK7ZeZDyx" crossorigin="anonymous"></script>

N'i bɛ baara Kɛ ni an ka JavaScript lajɛlen ye ani n'i b'a fɛ ka Popper.js Dòn a dan na, i bɛ Popper.js Fàra an ka JS kan, CDN fɛ a ka fisa.

<script src="https://code.jquery.com/jquery-3.5.1.slim.min.js" integrity="sha384-DfXdz2htPH0lsSSs5nCTpuj/zy4C+OGpamoFVy38MVBnE+IbbVYUew+OrCXaRkfj" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/umd/popper.min.js" integrity="sha384-9/reFTGAW83EW2RDu2S0VKaIzap3H66lZH81PoYlFhbGU+6BZp6G7niu735Sk7lN" crossorigin="anonymous"></script>
<script src="https://cdn.jsdelivr.net/npm/[email protected]/dist/js/bootstrap.min.js" integrity="sha384-w1Q4orYjBQndcko6MimVbzY0tgp4pWB4lZ7lr30WKz0vr/aWKhXdBNmNb5D92v7s" crossorigin="anonymous"></script>

Pake ɲɛmɔgɔw

Bootstrap ka source files sama ka don porozɛ suguya bɛɛ la ni pake ɲɛmɔgɔ dɔw ye minnu ka di kosɛbɛ. Foroko ɲɛnabɔbaga mana kɛ min o min ye, Bootstrap bɛna Sass daɲɛgafe ni Autoprefixer de wajibiya walasa ka sigicogo dɔ sɔrɔ min bɛ bɛn an ka daɲɛw labɛncogo ofisiyaliw ma.

npm ye

Bootstrap in sigi i ka Node.js baarakɛminɛnw kɔnɔ ni npm pake ye :

npm install bootstrap

require('bootstrap')bɛna Bootstrap ka jQuery fɛnw bɛɛ doni jQuery fɛn kan. Module bootstrapyɛrɛ tɛ foyi bɔ kɛnɛ kan. Aw bɛ se ka Bootstrap ka jQuery plugins kelen-kelen bɛɛ doni bolo la ni aw ye /js/*.jsfilenw doni pake ka sanfɛla ɲɛbila jukɔrɔ.

Bootstrap's package.jsonkɔnɔ, metadata wɛrɛw bɛ yen minnu bɛ nin kilisi ninnu jukɔrɔ:

  • sass- sira min bɛ taa Bootstrap ka Sass source fileba la
  • style- sira min bɛ taa Bootstrap ka CSS la min ma dɔgɔya min labɛnna ka kɔn ni sigicogo kɔrɔw ye (labɛnni tɛ kɛ) .

jirisun

Bootstrap in sigi i ka Node.js baarakɛminɛnw kɔnɔ ni jiri pake ye :

yarn add bootstrap

RubyGems ye

Bootstrap sigi i ka Ruby porogaramuw kɔnɔ ni Bundler ( ladilikan ) ani RubyGems ye i kɛtɔ ka nin zana in fara i ka Gemfile:

gem 'bootstrap', '~> 4.5.3'

O cogo kelen na, n’i tɛ Bundler baara, i bɛ se ka gem in sigi ni nin cikan in ye:

gem install bootstrap -v 4.5.3

Aw ye gem ka README lajɛ walasa ka kunnafoni wɛrɛw sɔrɔ.

Dɔnkilidala

Aw bɛ se fana ka Bootstrap ka Sass ni JavaScript sigi ani k’u ɲɛnabɔ ni Composer ye :

composer require twbs/bootstrap:4.5.3

NuGet ye

N’i ​​ye yiriwa .NET kɔnɔ, i bɛ se fana ka Bootstrap ka CSS walima Sass ani JavaScript in sigi ani k’a ɲɛnabɔ ni NuGet ye :

Install-Package bootstrap
Install-Package bootstrap.sass