![](https://img-blog.csdnimg.cn/20201014180756928.png?x-oss-process=image/resize,m_fixed,h_64,w_64)
Nodejs
文章平均质量分 52
玄岳
这个作者很懒,什么都没留下…
展开
-
MAC下安装node.js
一、安装Homebrewhttp://brew.sh ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"可能用到的brew命令brew listen 列出已安装的软件brew update 更新brewbrew home 用浏览器打开brew的官方网站原创 2015-07-08 21:37:11 · 416 阅读 · 0 评论 -
MAC上安装node-canvas
安装Node.js的canvas库时发现canvas依赖cairo包:$ npm install canvas...> node-gyp rebuild...No package 'cairo' found可以通过brew安装,但是安装时发现cairo依赖于X11:$ brew install cairocairo: Unsatisfied dependency:原创 2015-07-08 21:49:43 · 2423 阅读 · 0 评论 -
node.js中的process.nextTick()和setImmediate()
process.nextTick()和setImmediate()在node.js中都是将回调函数延时执行。跟setTimeout(function(){}, 0);类似,但性能不一样,setTimeout定时器是采用红黑树,process.nextTick()是用数组,setImmediate()是用链表。先看看process.nextTick()的代码process.nextTick(原创 2015-07-23 15:41:14 · 1279 阅读 · 0 评论