R.lift(fn) turns a plain n-ary function into one that works over lists (or other Apply values). It builds every combination of arguments from those lists, then runs fn on each combo. Part of Ramda Function since v0.7.0 (stable — not deprecated).
Warning: Arity comes from fn.length. Rest-parameter helpers have length === 0 — use R.liftN for those. R.lift(fn) is R.liftN(fn.length, fn).
Syntax
Call R.lift. Start with this line.
Ramda
R.lift(fn)
Call
What it does
R.lift(fn)
Primary signature.
R.lift(...)
Call the function helper.
Prefer import { lift } from "ramda" when you want a named import.
Binary concat. Two string lists → every pair joined.
First prefix. All Hi… results come before Hey….
Suffixs vary.! then ? for each prefix.
Use case. Small cartesian products of strings or tags.
Compatibility
Browser & Runtime Support
R.lift is a Ramda Function helper since v0.7.0. It runs anywhere Ramda runs — modern browsers (CDN or bundle) and Node.js / Bun / Deno with npm install ramda.
✓ Stable · Ramda 0.7.0+
R.lift()
Available in [email protected] full builds once the library is loaded. Works in evergreen browsers and current Node LTS when Ramda is installed. No extra browser API is required.
100%With Ramda 0.7.0+
Google ChromeSupported · Desktop & Mobile
Full support
Mozilla FirefoxSupported · Desktop & Mobile
Full support
Apple SafariSupported · macOS & iOS
Full support
Microsoft EdgeSupported · Chromium
Full support
Internet ExplorerNo native support · Use a polyfill
Polyfill
OperaSupported · Modern versions
Full support
Samsung InternetSupported · Android
Full support
BunSupported · JavaScript runtime
Supported
DenoSupported · JavaScript runtime
Supported
Node.jsSupported · Server runtime
Supported
Android WebViewSupported · Modern WebView
Full support
R.liftRamda 0.7.0+
Bottom line: Safe for production once Ramda is loaded (CDN or npm). Prefer a modular build if you tree-shake. Use liftN when fn.length does not match the arity you need.
Frequently Asked Questions
R.lift(fn) takes a function of arity 1 or more and returns a new function that maps over lists (or other Fantasy-Land Apply values) instead of plain values. The docs sample is R.lift((a, b, c) => a + b + c)([100, 200], [30, 40], [5, 6, 7]) //=> [135, 136, 137, 145, 146, 147, 235, 236, 237, 245, 246, 247]. Added in v0.7.0.
const madd3 = R.lift((a, b, c) => a + b + c); madd3([100, 200], [30, 40], [5, 6, 7]); //=> [135, 136, 137, 145, 146, 147, 235, 236, 237, 245, 246, 247]. Every combination of one number from each list is added. A five-argument sibling madd5 is also in the docs.
R.map runs one unary function over one list. R.lift runs an n-ary function over n lists, producing every combination (a cartesian product), then applying the function to each combo.
R.lift(fn) is R.liftN(fn.length, fn). Use lift when the function's .length is the arity you want. Use liftN when the function is variadic (rest args) so .length is 0 or too small.
The first list is the outermost loop, the last list is the innermost. For madd3([100, 200], [30, 40], [5, 6, 7]) you get 100+30+5, then 100+30+6, then 100+30+7, then 100+40+5, and so on.
No. R.lift is a stable Ramda function helper from v0.7.0. It is not deprecated, experimental, or non-standard.