Comments (1)
- Minify JavaScript。有些库混淆后不能工作了,比如angular,使用webpack的
ng-annotate
来解决。 - 先加载title,再在点击后取post内容。
通过提前使用脚本将title/path/content等元信息生成到json中的方式,可以直接从本地提取少量重要元信息。否则每次都要从文章内容中去提取。- 使用Nodejs的fs文件系统函数时,不要使用异步的方式:http://12devs.co.uk/articles/promises-an-alternative-way-to-approach-asynchronous-javascript/
- Nodejs提供了异步对应的同步版本:https://nodejs.org/api/fs.html#fs_fs_readsync_fd_buffer_offset_length_position
- Minify CSS。优先级较低,先提高取post的速度。
- 把每篇文章写到一个单独的json里面去,取的时候可以节省流量,现在要把所有文章的json拿过来,然后再从里面取。不好。
from ethanlin-twer.github.io.
Related Issues (20)
- 【博客2.0】文章详情页 - 评论功能
- 【博客2.0】文章详情页 - 点赞、点踩功能
- 【博客2.0】首页 - 列表
- 【博客2.0】首页 - 目录
- 【博客2.0】首页 - 专题
- 【博客2.0】草稿区 HOT 1
- 【博客2.0】个性化 - 他说 HOT 1
- 【博客2.0】个性化 - 日常 coding 数据展示
- 【博客2.0】清理 Github issues
- 【博客2.0】文章详情页 - 中英切换
- 【博客2.0】个性化 - 目标管理器
- 新的学习计划
- Angular 项目记,与 React 的对比
- 【博客3.0】使用 Vue 撸一遍博客
- 关于敏捷意识形态的探讨与在前端生产实践落地的想法
- 敏捷五问(一):为什么我们要做原子、小步提交 HOT 1
- Angular 单元测试策略 HOT 1
- 敏捷五问(二):为什么我们要做主干开发 HOT 1
- 哈哈哈哈,组件型写作。general ideas 多个地方都可以用,落地的具体实践部分,以几个具体原则做指导(相当于接口),再填充具体的东西就行…大家求变,要抓住不变!
- React单元测试最佳实践与前端TDD HOT 10
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from ethanlin-twer.github.io.