DEV Community

Discussion on: Array cheatsheet Javascript

Collapse
 
zalithka profile image
Andre Greeff

so... I also want to jump on the complaints wagon for a moment here: why is everything emphasized!? grr... this just makes the paragraphs unnecessarily difficult to read.

but yeah, two issues I spot here:

  • length is most definitely a property, not a method..
  • [1, 2, 3, 4, 5].join("-") does not result in [1-2-3-4-5].. this results in the string "1-2-3-4-5".

lastly, why are you showing the final result of calling these functions as though they were assignments? that in itself is also confusing AF.. so much so, that it might actually mislead anyone who is still learning the cute and cuddly monster that is JavaScript.

Collapse
 
franzcmarcelo profile image
franzDubs

...and you forgot to mention the spaces added to various string elements of the altered array 😅