Factory pattern is soo simple in JavaScript