utils.js 211 B

123456789101112
  1. export default {
  2. guid: () =>
  3. [1, 1, 0, 1, 0, 1, 0, 1, 0, 1, 1, 1]
  4. .map(b =>
  5. b
  6. ? Math.floor((1 + Math.random()) * 0x10000)
  7. .toString(16)
  8. .substring(1)
  9. : "-"
  10. )
  11. .join("")
  12. };