Re:How the Fuck Did We Get Here?
by 8note on Friday April 07, 2023 @08:38PM
(#35489083)
We got here because JS got really good at abstractions, but people have no interest in long term maintenance.
Using is-odd is fine, the same as developers using the "+" is fine in languages that support it. Where JS is weird is in not having a full standard library along with very arbitrary data, leading to folks seeing that they use the is-odd functionality regularly enough to where it's useful to have a dedicated operator
I'd use an is-odd library if I need to figure out if something is odd across 20 different data types depending on how somebody inputted data in a UI
Using is-odd is fine, the same as developers using the "+" is fine in languages that support it. Where JS is weird is in not having a full standard library along with very arbitrary data, leading to folks seeing that they use the is-odd functionality regularly enough to where it's useful to have a dedicated operator
I'd use an is-odd library if I need to figure out if something is odd across 20 different data types depending on how somebody inputted data in a UI