DEV Community


Discussion on: What programming best practice do you disagree with?

cschliesser profile image
Charlie Schliesser

In JavaScript, tendency has been to chain lots of Array methods together to create ninja code that filters, maps, reduces, and sorts all in 1 fell swoop, using ECMA6 shorthand syntax for arguments and return values. Sometimes this is great, sometimes it's a mixed bag, and sometimes it requires a microscope to see what's going on. There are lots of situations where it's so much more pleasurable to write

for (const foo of foos) {
    await foo.async(...);