Hacker News new | past | comments | ask | show | jobs | submit login

I don't think that's what he's arguing though—it's not a cache like memcached or anything, it's much more abstract than that. He's saying that calculating values derived from the program state should be as simple as possible, and not have other side effects.



Caching comes with a bunch of strings attached of which recalculating the values is the least problematic.


I think the name “cached value” is a red herring, as far as the mindset being described is considered. “Derived value” might be closer to the mark; the values are pure functions of other things, and to change the derived value you must change the things it depends on. There need not be any mention of storing that derived value in a cache and somehow invalidating it.




Consider applying for YC's Spring batch! Applications are open till Feb 11.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: