Do Static Types Make Code Neater?
Eric Elliott
352
Thanks for the comprehensive response, I definitely should look into “rtype”. I would agree if there is a high code coverage density and a strong team dynamic stuff might work (I guess highly experienced engineers get bored doing classes, dynamic stuff lets them to have some fun), but it’s ideal conditions, I was writing about real projects that often run in not such ideal conditions.
Btw using JSDoc you would have to make it treat your dynamic code like something typed using weird comments annotations (like “@constructor”, “@param {string}”, etc). So you still need types since you do describe them for JSDoc, why then don’t use a real typing.