--- id: bad87fee1348bd9acde08712 title: Usare il design responsivo con i contenitori fluidi di Bootstrap challengeType: 0 forumTopicId: 18362 dashedName: use-responsive-design-with-bootstrap-fluid-containers --- # --description-- Nella sezione HTML5 e CSS di freeCodeCamp abbiamo costruito una Cat Photo App. Ora torniamo ad essa. Questa volta, la stilizzeremo usando il popolare framework CSS responsivo Bootstrap. Bootstrap capirà quanto è largo lo schermo e risponderà ridimensionando i tuoi elementi HTML - da qui il nome design responsivo. Con un design responsivo, non c'è bisogno di progettare una versione mobile del tuo sito web. Si vedrà bene su dispositivi con schermi di qualsiasi larghezza. Puoi aggiungere Bootstrap a qualsiasi app inserendo il seguente codice nella parte superiore del tuo HTML: ```html ``` In questo caso, lo abbiamo già aggiunto per te a questa pagina dietro le quinte. Nota che è accettabile usare sia `>` che `/>` per chiudere il tag `link`. Per iniziare, dovremmo annidare tutto il nostro HTML (tranne il tag `link` e l'elemento `style`) in un elemento `div` di classe `container-fluid`. # --hints-- Il tuo elemento `div` dovrebbe avere la classe `container-fluid`. ```js assert($('div').hasClass('container-fluid')); ``` Il tuo elemento `div` dovrebbe avere un tag di chiusura. ```js assert( code.match(/<\/div>/g) && code.match(/
/g).length === code.match(/
= 8 && !$('.container-fluid').has("style").length && !$('.container-fluid').has("link").length); ``` # --seed-- ## --seed-contents-- ```html

CatPhotoApp

Click here for cat photos.

A cute orange cat lying on its back.

Things cats love:

Top 3 things cats hate:

  1. flea treatment
  2. thunder
  3. other cats
``` # --solutions-- ```html

CatPhotoApp

Click here for cat photos.

A cute orange cat lying on its back.

Things cats love:

  • cat nip
  • laser pointers
  • lasagna

Top 3 things cats hate:

  1. flea treatment
  2. thunder
  3. other cats
```