Extending javascript core api. inspired by underscore, Ruby and prototype