• 17 Posts
  • 1.79K Comments
Joined 2 年前
cake
Cake day: 2023年7月7日

help-circle


  • it’s turtles all the way regardless; but it’s much easier to handle side effects if you have more numerous but smaller functions.

    I prefer that because fully reading a module or component is not the most common scenario. The most common use case of reading code is (or should be) not caring about most of the implementation details until you need to; only then you have to go down the rabbit hole.

    Longer functions force the reader to understand most of their context every time they get there, a problem especially when the function has a bunch of local vars.