Sunday 15 June 2014

javascript - Passing a function with parameters as parameter of another function -


There are some similar questions, but the one is still confused. Because my case works with the parameter as the second function parameter.

Simple case:

  var that = 'old IE', dowhat = function caller (text, symbol) {} (that + dowet + mikecode);} warning (Text); Func ();}   

Question: caller (text, whatsapp (joe, dovat, mikeode)) something to do? I'm not sure if we use unknown functions like caller (text, function () {...} (is that unknown function called twice?)

itemprop = "text">

To pass a function to execute with the argument, you use lambda The lambda parameter is passed as func .

Example: (This caller - text , which is the call to , Dvatt , and mycode are parameters / variables. Lambda is still which , dvatt , and mycode )

  caller (text, work) (whathappen (joe, davat, mikeode);});   

"If I understand what you mean, maybe you have seen the syntax."

  (function () {...}} () ;   

Which Lambda is said immediately after construction (at the end of launching Lambda Notice the bracket) In the first example, you are creating and passing only anonymous functions (in JavaScript).

No comments:

Post a Comment