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.


This content originally appeared on DEV Community and was authored by SIDDHANT JOHARI

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.


This content originally appeared on DEV Community and was authored by SIDDHANT JOHARI


Print Share Comment Cite Upload Translate Updates
APA

SIDDHANT JOHARI | Sciencx (2021-07-03T20:08:16+00:00) Javascript Hacks. Retrieved from https://www.scien.cx/2021/07/03/javascript-hacks/

MLA
" » Javascript Hacks." SIDDHANT JOHARI | Sciencx - Saturday July 3, 2021, https://www.scien.cx/2021/07/03/javascript-hacks/
HARVARD
SIDDHANT JOHARI | Sciencx Saturday July 3, 2021 » Javascript Hacks., viewed ,<https://www.scien.cx/2021/07/03/javascript-hacks/>
VANCOUVER
SIDDHANT JOHARI | Sciencx - » Javascript Hacks. [Internet]. [Accessed ]. Available from: https://www.scien.cx/2021/07/03/javascript-hacks/
CHICAGO
" » Javascript Hacks." SIDDHANT JOHARI | Sciencx - Accessed . https://www.scien.cx/2021/07/03/javascript-hacks/
IEEE
" » Javascript Hacks." SIDDHANT JOHARI | Sciencx [Online]. Available: https://www.scien.cx/2021/07/03/javascript-hacks/. [Accessed: ]
rf:citation
» Javascript Hacks | SIDDHANT JOHARI | Sciencx | https://www.scien.cx/2021/07/03/javascript-hacks/ |

Please log in to upload a file.




There are no updates yet.
Click the Upload button above to add an update.

You must be logged in to translate posts. Please log in or register.