News for hackers. Stuff that matters.
Re:The Node Beginner Book, an introduction to Node.js, is no... by satoimo on Monday July 11, 2011 @06:36AM (#2750131)
Sure it's just sample code, but I spilled my coffee when I saw this:

  function sleep(milliSeconds) {     var startTime = new Date().getTime();     while (new Date().getTime() < startTime + milliSeconds); }

Someone likes feeding the garbage collector.

Re:The Node Beginner Book, an introduction to Node.js, is no... by ManuelKiessling on Monday July 11, 2011 @09:19AM (#2750526)
Did you see that it's just code to demonstrate blocking, i.e., to demonstrate how to NOT do it?