_wks.js 358 B

123456789101112
  1. var store = require('./_shared')('wks');
  2. var uid = require('./_uid');
  3. var Symbol = require('./_global').Symbol;
  4. var USE_SYMBOL = typeof Symbol == 'function';
  5. var $exports = module.exports = function (name) {
  6. return store[name] || (store[name] =
  7. USE_SYMBOL && Symbol[name] || (USE_SYMBOL ? Symbol : uid)('Symbol.' + name));
  8. };
  9. $exports.store = store;