Javascript Hacks

There are many amazing features in javascript that can make your life much simpler, In this blog, I have added 20 features that every javascript developer should know.

1.Resize the Array using an array. length.

2.Swapping of two Numbers.

3 Concatenating two or more arrays without causing server overload.

4.Use Filter in a different way.

5.Iterate on the map from 0 to n.

6.Replace all occurrences of a word in a string

7.Shortcut for conditions.
Here, I am explaining basic two examples we can implement in multiple ways.

8.String to number / Number to string.

9.Use the console in different ways.

10.Use console.table

11.Get the items near to last index of an array.

12.Get n power of any number.

13.Check the falsy or truly value.

14.Call a function by its name stored in a string using eval function.

15.typeof Operator.

16.yeild keyword

17.function* in javascript.

18.new.target in javascript

19.label statement.

20.Rest parameters Syntax.

Conclusion:
Thanks for reading it, In this blog I have explained some of the most used features of javascript, I will explain more features in next blog,
Please give feedback in responses.

9