Is this value a Symbol stored in the global cross-realm Symbol
registry?
var isRegisteredSymbol = require('is-registered-symbol');
var assert = require('assert');
assert(!isRegisteredSymbol(null));
assert(!isRegisteredSymbol(undefined));
assert(!isRegisteredSymbol('foo'));
assert(!isRegisteredSymbol(Symbol.iterator));
assert(!isRegisteredSymbol(Symbol()));
assert(isRegisteredSymbol(Symbol.for('yogurt')));
Simply clone the repo, npm install
, and run npm test