20160311
文章目录
《移动Web手册》读书笔记
nodejs process.env.NODE_ENV 配置
>
process.env is a reference to your environment, so you have to set the variable there.
To set an environment variable in Windows:
SET NODE_ENV=development
on OS X or Linux:
export NODE_ENV=development
在百度开放云中可以通过app.conf配置环境变量
https://bce.baidu.com/doc/BAE/GUIGettingStarted.html#.E9.85.8D.E7.BD.AEapp.conf
多行文字最后显示省略号及更多
单行文字省略号text-overflow: ellipsis;
123overflow: hidden;text-overflow: ellipsis;white-space: nowrap;多行文字省略号-webkit-line-clamp: 2;
12345overflow : hidden;text-overflow: ellipsis;display: -webkit-box;-webkit-line-clamp: 2;-webkit-box-orient: vertical;jquery.dotdotdot插件计算省略号和显示更多 http://dotdotdot.frebsite.nl/
html5 history操作访问历史
- history.length // 长度
- history.back()
- history.go()
- history.forward()
- history.pushState({page: 1}, “title 1”, “?page=1”);
- history.replaceState({page: 3}, “title 3”, “?page=3”);
- history.state
- popstate事件
- history.js