DEV Community

All about arrays in javascript

HARSH VATS on July 13, 2020

For beginners this article will be good lesson and for experts it would a good revision so that you don't google things again. After reading this a...
Collapse
 
w3nl profile image
Pieter Epeüs Wigboldus

If you like to do more with array's, there is a package that extend the array, where you can do some stuff that isn't available by default: npmjs.com/package/array-helpers
Code is clean and easy to understand.

Collapse
 
harshvats2000 profile image
HARSH VATS

The package has functions that can really help. Will definitely make an article on it soon.

Collapse
 
stlnick profile image
Nick

As mentioned already, great revision sheet. It collects some of the most common methods we'll use in a simple example with a simple explanation.
Love it!

Collapse
 
harshvats2000 profile image
HARSH VATS

Sounds like I should keep posting revision sheets on different topics. :)

Collapse
 
stlnick profile image
Nick

Not a bad idea if you ask me! Plus, if you ever feel like writing a more in depth article on all or some of these methods that's an easy link to pop in here!

"If you want a more in-depth look at push check out my other article." or something along those lines with a link there.

Thread Thread
 
harshvats2000 profile image
HARSH VATS

Great advice. Thanks. I will update this with links to more detailed explanation articles. :)

Collapse
 
vssj01 profile image
Sri Sai Jyothi

This article is helpful as a quick revision sheet 😊
Adding what happens to the length of the array after using these methods would make it perfect 👌

Collapse
 
harshvats2000 profile image
HARSH VATS

I will definitely edit it. Thank you for your review. When people like what I write I get encouraged to write more. :)

Collapse
 
habeebullahi01 profile image
Habeebullahi01

Thanks Harsh. I learned something new by reading your post. Good job.

Collapse
 
harshvats2000 profile image
HARSH VATS

Happy to hear that. :)

Collapse
 
volomike profile image
Mike Ross 🇺🇸

Be careful with Javascript arrays. Some wonky stuff can happen sometimes with memory management. dev.to/volomike/comment/f1f8 Know when to use an object, versus an array.