first pass at node.js generator