A controversial question, to be sure. Are the benefits really just having types? I come from a Ruby background, so I don't understand the hype.
Are types uniquely suited for frontend programming? Can't you get the same by using prettier? I feel like I"m missing something.
processLedgers(ledgers)
What do you pass in? An array? An object? What are the keys?
Without types you are relying on comments (notorious for being out of date) or reading the implementation.
Often the implementation will palm off the work to othe functions and objects and maybe event send it to an api or bits of it. To get a true picture of what ledgers needs to look like you need to either read a tonne of code or copy and paste some other code you hope is right.
With types you define in the type what is acceptable. Many times you don’t need to look at the function definition or the code it calls or the code it calls calls etc.
So types save you time, reduce bugs, and make you happy!