Seems to work on objects too
Closed this issue · 3 comments
martpie commented
Hi !
Could you add on the README it works on objects too ? (and it's quite performant)
I was afraid to do a md5(JSON.stringify(object))
(250ms), but md5(myobject)
seems to work in 1.5ms.
emn178 commented
Hi,
It does not support object. I think the md5 result is incorrect.
martpie commented
Well, I don't know if the md5 hash is correct, but there's an output different for every object I parse. And this was what I was looking to do a deep comparison. But maybe I've done something wrong.
martpie commented
After working a bit on it, it's true that it "shouldn't work" on objects. I'll turn myself to a simple JSON.stringify, thanks !