{"library":"remeda","title":"Remeda Utility Library","description":"Remeda is a modern, tree-shakable utility library for JavaScript and TypeScript, focusing on a functional programming paradigm with both \"data-first\" and \"data-last\" execution styles. It is currently at version 2.33.7 and receives frequent updates, often multiple bug-fix releases per month, with minor feature releases occurring periodically. Key differentiators include its robust, first-class TypeScript support, providing highly specific and accurate types for its extensive collection of utilities. Unlike older libraries, Remeda is designed from the ground up to support lazy evaluation through `pipe` and `piped`, offers full CJS and ESM compatibility, and ensures full code coverage with comprehensive runtime and type tests. It aims to provide a reliable and type-safe alternative to libraries like Lodash and Ramda, offering migration guides for users transitioning from those ecosystems.","language":"javascript","status":"active","last_verified":"Sun Apr 19","install":{"commands":["npm install remeda"],"cli":null},"imports":["import { pipe } from 'remeda';","import { map } from 'remeda';","import { unique } from 'remeda';"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"import { pipe, forEach, unique, take } from 'remeda';\n\nconst numbers = [1, 2, 2, 3, 3, 4, 5, 6];\n\nconst processedNumbers = pipe(\n  numbers,\n  forEach((value) => console.log(`Processing: ${value}`)), // Side effect\n  unique(), // Removes duplicates\n  take(3) // Takes the first 3 elements after uniqueness\n);\n\nconsole.log('Result:', processedNumbers);\n// Expected console output:\n// Processing: 1\n// Processing: 2\n// Processing: 2\n// Processing: 3\n// Processing: 3\n// Processing: 4\n// Processing: 5\n// Processing: 6\n// Result: [1, 2, 3]","lang":"typescript","description":"Demonstrates `pipe` for chaining multiple functional operations (forEach, unique, take) on an array in a data-first manner.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}