Ramda Adjunct

ramda-adjunct

Functional point-free programming is all about composition. When I’m building an application nowadays I use composition from top to bottom. I compose functions to create modules, modules to compose features and features to compose applications. For composing functions itself I use functional libraries. Namely my two most favorite lodash and Ramda.

While using these functional libraries, I found out that in every new project I was working on, I tend to create the same set of aggregate functions that I missed either from lodash or Ramda. Let me demonstrate on this snippet…

const { isString, negate } = require('lodash/fp');
const { isNil, complement } = require('ramda');

const isNotString = negate(isString);
const isNotNil = complement(isNil);

After realizing that I had to redefine these functions in every project I opened my browser and started to search for extensions to lodash and Ramda. I decided to narrow my search to Ramda only, because it seems that it is missing more functions related to my use-cases.

My search criteria were:

  • timestamp of last commit
  • 100% test coverage
  • quality documentation similar to Ramda

The results:

I could not find anything solid I could use. I found multiple fragmented libraries, some didn’t have tests at all, some did not have any documentation, some were buggy and some were focused on promise etc… Of course I could use combination of multiple libraries but again I am not going to build software on libraries without any test coverage.

Hence Ramda Adjunct was born.

Ramda Adjunct is based on three main principles

  1. Centralization
  2. 100% test coverage
  3. Impeccable documentation

Centralization

All Ramda recipes and aggregate utils not present in Ramda are centralized here. There is no more need for everybody to create their own utils in their own codebases.

100% test coverage

Creating custom aggregate utils or implementing recipes from Ramda wiki creates the defectiveness problem. The problem is caused by the absence of any tests. Ramda Adjunct keeps 100% code coverage and mimics the Ramda test patterns.

Impeccable documentation

You cannot call a library great without a great documentation. Ramda Adjunct generates its documentation directly from its codebase and uses patterns both found in Ramda and Lodash to document its API.

What are the future plans ?

My first priority for the near feature is to absorb obsolete and no longer maintained Ramda Cookbook implementation and implement all `Type` related functions that I’m missing in Ramda. After that I would like to continue absorbing other `dead` libraries.

Ramda Adjunct repo is ready to receive pull requests. If you have some recipes you would like to share with the community, please issue a pull request or create an issue on Github.

Original article was published on linkedin pulse.

Ramda Adjunct

Ramda Adjunct is the most popular and most comprehensive set of utilities for use with Ramda, providing a variety of useful, well tested functions with excellent documentation.

Vladimir Gorej

Written by

Ramda Adjunct

Ramda Adjunct is the most popular and most comprehensive set of utilities for use with Ramda, providing a variety of useful, well tested functions with excellent documentation.

Welcome to a place where words matter. On Medium, smart voices and original ideas take center stage - with no ads in sight. Watch
Follow all the topics you care about, and we’ll deliver the best stories for you to your homepage and inbox. Explore
Get unlimited access to the best stories on Medium — and support writers while you’re at it. Just $5/month. Upgrade