- head里的css文件体积较大,加载时间较长
- 要求不仅能够尽快展现东西给用户(需要尽快加载、解析完相应的html+css),还要让用户能够尽快交互某些东西(在此以搜索框为例,需要尽快加载、解析完相应的html+js)
- 对不支持预加载的浏览器
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/** | |
* The first commented line is your dabblet’s title | |
*/ | |
html, body { | |
background: #f06; | |
height: 100%; | |
} | |
#ctn { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.hd, .ft { | |
height: 20px; | |
background-color: red; | |
} | |
.bd::after { | |
content: ''; | |
clear: both; | |
height: 0; | |
line-height: 0; | |
visibility: hidden; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.hd, .ft { | |
height: 20px; | |
background-color: red; | |
} | |
.bd::after { | |
content: ''; | |
clear: both; | |
height: 0; | |
line-height: 0; | |
visibility: hidden; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.hd, .ft { | |
height: 20px; | |
background-color: red; | |
} | |
.bd { | |
overflow: hidden; | |
} | |
.bd::after { | |
content: ''; | |
clear: both; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.hd, .ft { | |
height: 20px; | |
background-color: red; | |
} | |
.bd { | |
overflow: hidden; | |
} | |
.bd::after { | |
content: ''; | |
clear: both; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
.foo:before { | |
content: attr(data-line-number); // equal `content: 95` | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
JSON.parse('') | |
// SyntaxError: Unexpected end of input | |
JSON.parse('vds') | |
// SyntaxError: Unexpected token v |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function check() { | |
var hash = {}, | |
key, | |
times = Math.pow(10, 9), | |
i = 1; | |
do { | |
key = create3(); | |
if (hash[key]) { |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
git checkout topic-branch | |
git rebase master | |
git checkout master | |
git merge topic-branch |
NewerOlder