• 0 Posts
  • 5 Comments
Joined 1 year ago
cake
Cake day: June 22nd, 2023

help-circle
  • I personally don’t think that’s the issue with the typing system. With vanilla js if I’m looking at a function that has say four parameters that are not trivial objects like strings but are actually complex (think dependency injection) it’s very difficult for me to know what these objects are other than reading through the code of the function.

    Actually, even if the parameters are simple, I’m not sure of that until I look into the function and see what it’s doing. This is a huge pain in the ass most the time, because I just wanna look at the function name its parameters and move on. However, that being said, most of this can be remedied with jsdocs and a good linter/lsp.



  • Time zones are part of it, but also daylight savings is a real pain in the ass. And like you said it gets particularly complicated when you’re dealing with a system that deals with these things as an afterthought, which seems to be a lot of older libraries for time. For instance, the Java date utils are a nightmare and are now considered semi deprecated replaced by a new java.time api. That is, of course, no help for the ridiculous amount of things that depend on these stupid date utils and no one wants to spend the dev hours to refactor.


  • I thought Tail recursion just gets turned into an iterative loop by the compiler? Hence why you won’t get a stack overflow. And since in procedural languages you can just use a loop in place of a tail recursive function you would never run into this problem, right? At least this is how it was taught to me when I was learning about it in lisp.