How to deal with dirty side effects in your pure functional JavaScript | Hacker News Reader