normaliseKey.js 301 B

123456789
  1. export function normaliseKey(key) {
  2. // Cast the key to a string, as that's all we can set as a key.
  3. if (typeof key !== 'string') {
  4. console.warn(`${key} used as a key, but it is not a string.`);
  5. key = String(key);
  6. }
  7. return key;
  8. }
  9. //# sourceMappingURL=normaliseKey.js.map