Review : Build a Network Application with Node

I had the opportunity to review the PACKT video series “Build a Network Application with Node” by Joe Stanco.  This video series walks you through how, at a high-level, to create different types of web apps using Node.JS.

This video series targets the JavaScript developer with a basic understanding of Node.JS.  Joe Stanco does an excellent job in guiding the viewer through the creation of a series of web apps designed to highlight common develop use cases.  The examples start with a barebones “hello world” type app and gradually move the viewer to a more complex Socket.IO and Bootstrap app.

Joe Stanco’s presentation skills are impressive, from introduction to conclusion his delivery was clear, easy to understand, and in sync with his examples.  With a length of over 2 hours, the pace and clarify of presentation made “Build a Network Application with Node” easy to watch in a single sitting.

I do wish this was divided into a “Fundamentals” and “Advanced” course.  This would allow for Joe to spend more time on the advanced topics.

You can check out a sample section of “Build a Network Application with Node” on YouTube here.

Generating GUIDs in JavaScript

My last few projects required the use of GUIDs in a variety of ways.  While searching for an all JavaScript approach, I stumbled across a great stackoverflow question “How to create a GUID / UUID in Javascript?”Broofa provided an elegant solution to this problem which I’ve placed into a CommonJS module to make it easy to use in Titanium.

CommonJS Module:

exports.generate = function(){
	var guid = 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, function(c) {
	    var r = Math.random()*16|0, v = c == 'x' ? r : (r&0x3|0x8);
	     return v.toString(16);
	});		
	return guid;
};

View as gist

Generating a GUID in Titanium:

Ti.API.info("Require the CommonJS module");
var guid = require("guidtools");

Ti.API.info("Requesting a new guid");
Ti.API.info("GUID value = " + guid.generate());

View as gist

The above generates the below in your console window.

GUIDOutput