isSymbolRaw
Returns true
if the given object
is a Symbol
. Otherwise, returns false
.
const util = require('node:util');
util.isSymbol(5);
// Returns: false
util.isSymbol('foo');
// Returns: false
util.isSymbol(Symbol('foo'));
// Returns: true
Content copied to clipboard
Since
v0.11.5