ramda: Human readable type errors

Late last night I was coding and got a few TypeErrors here and there, for example from accidentally applying toUpper to a list.

node_modules/ramda/dist/ramda.js:5220
            return target[method].apply(target, args);
                                 ^
TypeError: Cannot read property 'apply' of undefined

So I wondered aloud on gitter room if it was in any way feasible for Ramda to provide a bit of hand holding in this respect and show a more friendly error message in case some thing like that happens.

Thoughts?

About this issue

  • Original URL
  • State: closed
  • Created 9 years ago
  • Comments: 25 (24 by maintainers)

Most upvoted comments

seems very much counter to the spirit of JS

One could also say that Ramda already has a completely strongly typed API so it is already not embracing the dynamic aspects of JavaScript. The dispatch mechanism on the other hand embraces duck typing.