filmov
tv
Slice vs splice JavaScript array methods
Показать описание
JavaScript has tons of different array methods which can be really hard to keep track of. Here is the difference between slice and splice and a trick to remember what they do once and for all.
While slice simply selects items out of an existing array to copy to a new one, splice modifies an existing array in place. Committing the difference between these two methods to memory is not required for JavaScript developers but it can make your life a little bit easier if you put in a couple minutes to memorize it now.
In this playlist
While slice simply selects items out of an existing array to copy to a new one, splice modifies an existing array in place. Committing the difference between these two methods to memory is not required for JavaScript developers but it can make your life a little bit easier if you put in a couple minutes to memorize it now.
In this playlist