Ramda.js R.none() Method

Beginner
5 min read
Updated: Nov 2026
5 examples
List

Definition

A list function that answers one yes-or-no question: does no item pass this test? R.none(fn, list) returns true when fn never matches, and false as soon as one item does. It is the Ramda version of !array.some(fn).

Status: stable since Ramda v0.12.0 — not deprecated, experimental, or non-standard.

Syntax

Call R.none. Start with this line.

Ramda
R.none(fn, list)
CallWhat it does
R.none(fn, list)Primary signature.
R.none(...)Call the list helper.

Prefer import { none } from "ramda" when you want a named import.

Library declarations
Ramda
R.none(fn, list)

Parameters

ParameterDescription
fnRequired. Test function, called with one item at a time
listRequired. The array to check (never changed)

Return Value

Return ValueDescription
*true if no item passes, otherwise false

Ramda Examples

Example 1 — Official: No Evens, Then No Odds

The two samples from the Ramda docs.

Ramda
const isEven = n => n % 2 === 0;
const isOdd = n => n % 2 !== 0;

console.log(R.none(isEven, [1, 3, 5, 7, 9, 11]));  // → true
console.log(R.none(isOdd, [1, 3, 5, 7, 8, 11]));   // → false
Try It Yourself

How It Works

  1. First call. Every number is odd, so isEven never returns true → true.
  2. Second call. isOdd(1) is already true.
  3. Result. One match is enough, so the answer is false.

Example 2 — It Stops at the First Match

Count how many times the test runs.

Ramda
let checks = 0;
const isOverTen = n => {
  checks += 1;
  return n > 10;
};

console.log(R.none(isOverTen, [1, 20, 3, 40]));  // → false
console.log(checks);                             // → 2
Try It Yourself

How It Works

  1. Check 1. 1 > 10 is false, so it moves on.
  2. Check 2. 20 > 10 is true — a match.
  3. Stop. R.none returns false right away; 3 and 40 are never tested.

Example 3 — Empty List Is Always true

Nothing to check means nothing matched. Add a guard if that should fail.

Ramda
const isNegative = n => n < 0;

console.log(R.none(isNegative, []));       // → true

const noNegatives = xs => xs.length > 0 && R.none(isNegative, xs);
console.log(noNegatives([]));              // → false
console.log(noNegatives([4, 9]));          // → true
Try It Yourself

How It Works

  1. Empty. There are no items, so the test never runs and the answer is true.
  2. Guard. xs.length > 0 is false for [], so && returns false without calling R.none.
  3. Real list. [4, 9] passes the guard and has no negatives → true.

Example 4 — Validate a Shopping Cart

Make sure no item in the cart is sold out.

Ramda
const cart = [
  { name: "Pen", stock: 12 },
  { name: "Ink", stock: 3 }
];
const isSoldOut = item => item.stock === 0;

console.log(R.none(isSoldOut, cart));      // → true

const bigCart = R.append({ name: "Pad", stock: 0 }, cart);
console.log(R.none(isSoldOut, bigCart));   // → false
Try It Yourself

How It Works

  1. Test. isSoldOut looks at one object and checks its stock.
  2. Clean cart. Pen and Ink both have stock, so nothing matches → true.
  3. New cart. R.append adds a sold-out Pad to a copy; that one match gives false.

Example 5 — A Reusable “No Blanks” Checker

R.none is curried, so give it the test now and the list later.

Ramda
const noBlanks = R.none(R.isEmpty);

console.log(noBlanks(["Ada", "Grace"]));  // → true
console.log(noBlanks(["Ada", ""]));       // → false
Try It Yourself

How It Works

  1. Partial call. R.none(R.isEmpty) returns a function still waiting for a list.
  2. Test. R.isEmpty is true only for "" here.
  3. Reuse. The first list has no blanks → true; the second has "" → false.

Browser & Runtime Support

R.none was added in Ramda v0.12.0. Ramda’s browser build is plain ES5, so it runs in any modern browser and in Node.js / Bun / Deno with npm install ramda.

✓ Stable · Ramda 0.12.0+

R.none()

A simple loop over the list, so no special browser API is needed. It has been part of Ramda for many years, so almost every project version includes it.

100% With Ramda 0.12.0+
Google Chrome Supported · Desktop & Mobile
Full support
Mozilla Firefox Supported · Desktop & Mobile
Full support
Apple Safari Supported · macOS & iOS
Full support
Microsoft Edge Supported · Chromium
Full support
Internet Explorer No native support · Use a polyfill
Polyfill
Opera Supported · Modern versions
Full support
Samsung Internet Supported · Android
Full support
Bun Supported · JavaScript runtime
Supported
Deno Supported · JavaScript runtime
Supported
Node.js Supported · Server runtime
Supported
Android WebView Supported · Modern WebView
Full support
R.none Ramda 0.12.0+

Bottom line: Safe for production with any modern Ramda release. The labs on this page use [email protected].

Frequently Asked Questions

R.none(fn, list) returns true when no item in the list passes the test fn, and false as soon as one item does. Docs sample: R.none(isEven, [1, 3, 5, 7, 9, 11]) //=> true.
true. An empty list has no items, so no item can match. If an empty list should count as a failure, check the length first: xs.length > 0 && R.none(fn, xs).
R.none is true when zero items pass. R.all is true when every item passes. R.any is true when at least one item passes. R.none(fn, list) always equals !R.any(fn, list), but it is not the same as !R.all(fn, list).
Only when nothing matches. It walks the list from left to right and returns false at the first item that passes the test, so the remaining items are never checked.
!array.some(fn). R.none puts the test first and is curried, so R.none(fn) gives you a reusable checker that waits for a list.
No. R.none has been a stable Ramda list function since v0.12.0 — not deprecated, experimental, or non-standard.

Next: R.nth()

Learn how to get the item at any index, including negative ones.

R.nth() tutorial →

About the author

Mari Selvan M P
Mari Selvan M P 🔗

Developer, cloud engineer, and technical writer

  • Experience 12 years building web and cloud systems
  • Focus Full Stack Development, AWS, and Developer Education

I write practical tutorials so students and working developers can learn by doing—from databases and APIs to deployment on AWS.

6 people found this page helpful