Skip to content

Comment on 21 Nested Callbacksparent

Comments

Yes, but that "patience to grind endlessly" is typically applied towards a different goal.

Sure, you can spend an afternoon or so to write and debug those 20 nested callbacks, but surely, it is more fun and thus better to spend a couple of _days_ thinking of the problem, googling for solutions, getting distracted by some nice algorithm, attempting to apply that in a totally distinct, perfectly working part of your codebase, renaming a couple of functions, etc., and finally replace that nested thing with some carefully placed '.each' or '.map' (after gauging which solution looks best, aesthetically)

Yes, there may be commercial pressure to ship a product, but in the hearts of many programmers, the journey is the reward.

AboutSource Built by g1lg1l

Hackerly is an independent reader for Hacker News, built on the public HN API. Not affiliated with Y Combinator.