Functional Programming guidelines for Javascript