Open stevegeek opened 1 year ago
sqids says "...multiple IDs can decode back into the same sequence of numbers. If it's important to your design that IDs are canonical, you have to manually re-encode decoded numbers and check that the generated ID matches." .. is this true also of hashids?
Sqids replace hashids , see https://sqids.org/ruby but are not backwards compatible
Upgrading to a v2 will require using a prefix on any new IDs to allow you to differentiate and if you have hash ID type ids in the wild, you will need to run both side by side and pick the right decoder... maybe the library can do this for you, ie be configured to support decoding older hashids (eg by identifying them someway, eg by format)