Skip to content

Instantly share code, notes, and snippets.

View binnng's full-sized avatar
🎯
Focusing

binnng binnng

🎯
Focusing
View GitHub Profile
@binnng
binnng / gist:5394044
Created April 16, 2013 07:23
box-shadow VS dropshadow
<!doctype html>
<html>
<style rel="stylesheet">
div{
width: 60px;
height: 60px;
background: url(http://xnimg.cn/modules/global-publisher/res/tl-photo.png) center no-repeat;
}
.box_shadow{
@binnng
binnng / gist:5393529
Created April 16, 2013 05:12
display: run-in,追加到后一个block元素的里面
<!doctype html>
<html>
<style rel="stylesheet">
.inner{
height: 40px;
background-color: #f33;
}
.fir{
@binnng
binnng / gist:5393320
Last active December 16, 2015 06:39
多行文字居中显示
<!doctype html>
<html>
<head>
<meta charset="utf-8" />
<style>
.box{
width: 200px;
height: 200px;
background: #CCC;
display: table-cell;
@binnng
binnng / gist:5378625
Last active December 16, 2015 04:39
bg.png和pic.png谁先加载?
<!doctype html>
<html>
<style type="text/css" rel="stylesheet">
#bg{background:url(bg.png)}
</style>
<div id="bg"></div>
<img src="pic.png" />
</html>
@binnng
binnng / gist:5372523
Last active December 16, 2015 03:49
Object.create创建对象, 疑惑的地方。具体看代码
var O = {a: 1};
var n = Object.create(O, {
a: {
value: 2
}
});
console.log(n); //{a: 1}