提交学习笔记专用
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

26 lines
766 B

  1. export { digest } from 'ohash/crypto';
  2. export { i as isEqual } from './shared/ohash.CMR0vuBX.mjs';
  3. /**
  4. * Serializes any input value into a string for hashing.
  5. *
  6. * This method uses best efforts to generate stable serialized values.
  7. * However, it is not designed for security purposes.
  8. * Keep in mind that there is always a chance of intentional collisions caused by user input.
  9. *
  10. * @param input any value to serialize
  11. * @return {string} serialized string value
  12. */
  13. declare function serialize(input: any): string;
  14. /**
  15. * Hashes any JS value into a string.
  16. *
  17. * The input is first serialized and then hashed.
  18. *
  19. * @param input any value to serialize
  20. * @return {string} hash value
  21. */
  22. declare function hash(input: any): string;
  23. export { hash, serialize };