var date = \"2012-01-18T16:03\";
var date = new Date(date);
console.log(date.getMinutes());
console.log(date.getMinutes().length)
This returns 3.
I usually use this piece of code :
var start = new Date(timestamp),
startMinutes = start.getMinutes() < 10 ? '0' + start.getMinutes() : start.getMinutes();
It is quite similar to the @ogur accepted answer but does not concatenate an empty string in the case that 0 is not needed. Not sure it is better. Just an other way to do it !