Remeda

A utility library for JavaScript and TypeScript.
GitHub
4.54k
Created 7 years ago, last commit 4 days ago
95 contributors
569 commits
Stars added on GitHub, month by month
11
12
1
2
3
4
5
6
7
8
9
10
2023
2024
Stars added on GitHub, per day, on average
Yesterday
+6
Last week
+1.9
/day
Last month
+1.7
/day
Last 12 months
+2.8
/day
npmPackage on NPM
remeda
2.17.3
Monthly downloads on NPM
11
12
1
2
3
4
5
6
7
8
9
10
2023
2024
README

Remeda

The first "data-first" and "data-last" utility library designed especially for TypeScript.

GitHub License GitHub top language NPM NPM Downloads GitHub Repo stars Libraries.io SourceRank
Codecov GitHub branch status GitHub Release Date Commits All contributors

Documentation

Read the full docs and API reference on remedajs.com/docs.

Migrating from other libraries? Check out our migration guides for Lodash and Ramda!

Interested in contributing? Read the contributing guide.

Features

  • First-class TypeScript support, with types that are as specific as possible.
  • Supports data-first (R.filter(array, fn)) and data-last (R.filter(fn)(array)) approaches.
  • Lazy evaluation support with pipe and piped.
  • Runtime and types are both extensively tested, with full code coverage.
  • Tree-shakable, supports CJS and ESM.
  • Fully documented with JSDoc, supports in-editor function documentation.

Getting started

Installation

npm install remeda
pnpm add remeda
yarn add remeda
bun install remeda

Usage

// Import everything:
import * as R from "remeda";

// Or import methods individually:
// import { pipe, tap, unique, take } from "remeda";

R.pipe(
  [1, 2, 2, 3, 3, 4, 5, 6],
  R.tap((value) => console.log(`Got ${value}`)),
  R.unique(),
  R.take(3),
); // => [1, 2, 3]

// Console output:
// Got 1
// Got 2
// Got 2
// Got 3

Getting help

Questions, bug reports, and feature requests are tracked in GitHub issues.

Contributors

Made with contrib.rocks.