2013-01-15 18 views
8

Sto iniziando un progetto che sto utilizzando Twitters Bootstrap per e mi chiedevo se avesse le sue regole di reset.Normalizza foglio di stile con bootstrap Twitter

Normalmente faccio plonk in un foglio di stile normalizzato per aiutare i miei siti a visualizzare un cross browser più coerente, ma è necessario con Bootstrap?

+0

utilizza [normalize.css] (http://necolas.github.com/normalize.css/) –

risposta

21

Bootstrap utilizza già normalize.css. Date un'occhiata a the source (e la LESS file):

/*! 
* Bootstrap v2.2.2 
* 
* Copyright 2012 Twitter, Inc 
* Licensed under the Apache License v2.0 
* http://www.apache.org/licenses/LICENSE-2.0 
* 
* Designed and built with all the love in the world @twitter by @mdo and @fat. 
*/ 

article, 
aside, 
details, 
figcaption, 
figure, 
footer, 
header, 
hgroup, 
nav, 
section { 
    display: block; 
} 
3

Bootstrap v3 rende ora questo esplicito e include anche il numero di versione:

/*! 
* Bootstrap v3.0.3 (http://getbootstrap.com) 
* Copyright 2013 Twitter, Inc. 
* Licensed under http://www.apache.org/licenses/LICENSE-2.0 
*/ 

/*! normalize.css v2.1.3 | MIT License | git.io/normalize */ 

article, 
aside, 
details, 
figcaption, 
figure, 
footer, 
header, 
hgroup, 
main, 
nav, 
section, 
summary { 
    display: block; 
} 

Nota che normalize.css è ora a v3.0.0- rc.1 quindi potresti voler guardare il CHANGELOG o il diff e valutare se desideri utilizzarli sul tuo sito.