DEV Community

Cover image for 20 Array methods in Typescript you need to know with examples
Raksha for Canopas Software

Posted on

3 1

20 Array methods in Typescript you need to know with examples

We, programmers, play with Arrays all the time, and yet most of the time we don’t know all helper functions provided by the TypeScript.

Pre-built functions have always been proved time-savers. Find the list of utility functions in typescript with demonstrations.

I have listed out 20 methods that you need to know, with fun emojis.

indexOf()
lastIndexOf()
concat()
join()
push()
pop()
reverse()
shift()
unshift()
slice()
splice()
toString()
filter()
map()
every()
reduceRight()
reduce()
some()
sort()
fill()
Full article with example available an on canopas blog.

The full source code is available on Github.

Top comments (0)

A Workflow Copilot. Tailored to You.

Pieces.app image

Our desktop app, with its intelligent copilot, streamlines coding by generating snippets, extracting code from screenshots, and accelerating problem-solving.

Read the docs

👋 Kindness is contagious

Please leave a ❤️ or a friendly comment on this post if you found it helpful!

Okay