r/javascript • • Aug 27 '16

Is your JavaScript function actually pure?

http://staltz.com/is-your-javascript-function-actually-pure.html
8 Upvotes

48 comments sorted by

View all comments

-1

u/DrGarbinsky Aug 27 '16

Who cares if it is pure?

5

u/misc_ent Aug 27 '16

Anyone who doesn't want side effects in their functions? Not trying to be snarky as that's literally the reason.

9

u/Prince_Houdini Aug 27 '16

I don't want side effects in my functions, but I don't care if my functions are "pure" in the sense the author uses here. The colloquial sense of pure - same input = same output in normal circumstances - is enough for me.