Anonymous Function in Javascript

 Anonymous Function in Javascript

In this article we are goanna to see about Anonymous Function in Javascript and where we use these. which is most important when you are going to start your career in JavaScript. Please ready and enjoy this article if you want to give any feedback about your experience, we welcome.





In Anonymous functions no need to define specific function name. 

Can be stored in a variable

Can be returned in a function

Can be pass in a function


Syntax :

function ( ) {

body of function;

};

Ex :

var myfunction = function(){

document.write(“Hello world”)

};

myfunction();


Share:

0 comments

Please leave your comments...... Thanks