New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
disable sorting of arrays #15
Comments
Hi. Currently it's not supported. But I think it's easy to add such option. It would be non-breaking change, and quiet easy to implement. If you would like to submit a PR, you're welcome. If not, I think I could find some time by the next weekend to add this. |
thanks, I've added a |
@adrian-gierakowski good. |
If you still interested I've implemented granular sorting control options. The changes aren't published yet, but you may preview them in https://github.com/SkeLLLa/node-object-hash/tree/next branch. Now it will add possibility to control what kind of items you need to sort. Also it allows to disable type coercion(https://github.com/SkeLLLa/node-object-hash/blob/next/docs/interfaces/objectsorter.coerceoptions.md). I think it will be released in near future (~ in a week I think). But that would be v2.0.0. |
Version 2.0.0-rc.1 released to npm.You may install it via It should contains all features you wanted: |
Released in v2.0.0. Feel free to test and reopen if it doesn't work as expected. |
I'd like to be able to disable the sorting of arrays, so that
hash([1,2] != hash([2,1])
, while keeping all other "object" types sorted. Is this currently possible?The text was updated successfully, but these errors were encountered: