// package
is-set
type: "module"
// preferences
// replacements (1)
snippet::is-set
Simple or drop-in replacementThis package is no longer necessary. You can use `instanceof Set` to check if a value is a `Set`, or if cross-realm, use `Object.prototype.toString.call(v) === "[object Set]"`
// example
const isSet = v instanceof Set;
// for cross-realm
const isSetCrossRealm =
Object.prototype.toString.call(v) ===
'[object Set]';