A patch for JavaScript Date object which adds the format functionality when converting to string