toPropertyKey.js 252 B

12345678910
  1. var _typeof = require("../helpers/typeof");
  2. var toPrimitive = require("./toPrimitive");
  3. function _toPropertyKey(arg) {
  4. var key = toPrimitive(arg, "string");
  5. return _typeof(key) === "symbol" ? key : String(key);
  6. }
  7. module.exports = _toPropertyKey;