Jason Knight
1 min readJul 11, 2020

--

Almost all the code in your examples is either broken, or poster children for everything WRONG with the needlessly cryptic arrow functions, pointlessly redundant Object.keys, and the general lack of knowledge those who seem so ready to embrace these things bring to the table.

Take your Object.keys where you're getting the Key's index in the new Array INSTEAD of the value from the original object! Or your filtering example that doesn't include the variable actually being tested.

Even just the endless pointless "LET for nothing". If you have multiple VAR/LET/CONST in a row, say it ONCE and then comma delimit.

Though a lot of what you're showing here is neat, it all lacks clarity due to being symbol based, and for me still isn't real world deployable since I don't use JS server-side and client side most of my clients STILL (string of expletives omitted) insist on at LEAST IE 11 support, and a few even demand {even stronger list of profanity omitted) IE8 support.

When things like the derpy arrow function throws a parser level error in all versions of IE by their mere presence; though I have used that to my advantage in a few cases as a form of capabilities detection so I can tell clients "the page still works in IE, it just gracefully degrades to not get the bells and whistles"

--

--

Jason Knight
Jason Knight

Written by Jason Knight

Accessibility and Efficiency Consultant, Web Developer, Musician, and just general pain in the arse

Responses (1)