You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I've just found out that the generation of UUIDs without a namespace are not standard, all other implementations found online and in other programming languages requires providing a namespace and a name.
The specification explicitly says to use a namespace during generation:
"o Compute the hash of the name space ID concatenated with the name."
Should you specify in the documentation about library's non-standard function?
Another solution would be using a nil UUID as namespace in cases when user provides no namespace (but that will break current tests that check the generation of UUID without a namespace).
The text was updated successfully, but these errors were encountered:
I've just found out that the generation of UUIDs without a namespace are not standard, all other implementations found online and in other programming languages requires providing a namespace and a name.
The specification explicitly says to use a namespace during generation:
Currently your library concatenates an empty array that results in using just the data of the provided name for hashing without any data of the namespace: https://github.com/danakt/uuid-by-string/blob/master/src/index.js#L35
Should you specify in the documentation about library's non-standard function?
Another solution would be using a nil UUID as namespace in cases when user provides no namespace (but that will break current tests that check the generation of UUID without a namespace).
The text was updated successfully, but these errors were encountered: