Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

The reason why the use of generic and Ramda library's curry() together doesn't result in the application of generic is because curry() is a specific function that only works with Ramda's functional programming paradigm. On the other hand, generic is a generic utility library that works with any programming paradigm. The two libraries have different design patterns and philosophies, which makes it difficult to combine them seamlessly.

Currying is a technique used in functional programming that allows us to partially apply a function's arguments and return a new function that takes the remaining arguments. This technique is useful for creating reusable functions that can be composed with other functions. Ramda's curry() function works by returning a new curried function that takes its arguments one at a time.

Generic, on the other hand, is a library that provides utility functions for all JavaScript developers, regardless of their programming paradigm. It provides a set of functions that can be used to perform common tasks, such as manipulating arrays, strings, and objects.

While it's certainly possible to use curry() with generic, there's no guarantee that the two libraries will work seamlessly together. This is because they have different design patterns and philosophies, which can lead to unexpected behavior when used together. In general, it's best to use libraries that are designed to work together, rather than trying to mix and match unrelated libraries.