types.isSetIterator - Node documentation
function types.isSetIterator

Usage in Deno

import { types } from "node:util";
const { isSetIterator } = types;
isSetIterator(object: unknown): boolean

Returns true if the value is an iterator returned for a built-in Set instance.

const set = new Set();
util.types.isSetIterator(set.keys());  // Returns true
util.types.isSetIterator(set.values());  // Returns true
util.types.isSetIterator(set.entries());  // Returns true
util.types.isSetIterator(set[Symbol.iterator]());  // Returns true

Parameters

object: unknown

Return Type

boolean