Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Totally agree with you re: DI as a way to structure your code.

I tend to start with function passing and yeah, when it gets to 5 functions you start putting them in a class or other structure that allows you to pass them as a unit. I like using tuples to pass gobs functions because it works better with type-inference in F#

I've just never heard it referred to as DI except in OO (Java) circles.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

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

Search: