@elizaos/core v1.0.0-beta.7 / stringToUuid
Function: stringToUuid()
stringToUuid(
target
): `${string}-${string}-${string}-${string}-${string}`
Converts a string or number to a UUID.
Parameters
• target: string
| number
The string or number to convert to a UUID.
Returns
`${string}-${string}-${string}-${string}-${string}`
The UUID generated from the input target.
Throws
Throws an error if the input target is not a string.