Pure Javascript Functions


A pure function gives you the same output with the same input. The output of these functions doesn't depend upon global variables. That is, it is free from side effects.web design company in Chennai. web design company in Velachery.



advantages:

   Easy to test

   Easy to debug

   Easy to understand 

some inbuilt javascript functions that are pure :

map(), filter(), reduce(), concat(),etc..

web design company in Chennai. web design company in Velachery.

Comments

Popular posts from this blog