Skip to main content
Module

x/isx/mod.ts>isIterable

TypeScript-first is function collections
Go to Latest
function isIterable
import { isIterable } from "https://deno.land/x/isx@1.0.0-beta.18/mod.ts";

Whether the value is Iterable or not.

Parameters

value: unknown
  • Any value.
import { isIterable } from "https://deno.land/x/isx@$VERSION/mod.ts"
import { assertEquals } from "https://deno.land/std@$VERSION/testing/asserts.ts"
assertEquals(isIterable(""), true)
assertEquals(isIterable({}), false)

Returns

value is Iterable<T>