Run Code
|
API
|
Code Wall
|
Misc
|
Feedback
|
Login
|
Theme
|
Privacy
|
Patreon
example for node promises
//nodejs v4.2.6 function first(val){ var d=val+10; console.log("first",d); return d; } function second(val){ var d=val+10; console.log("second",d); return d; } function third(val){ var d=val+10; console.log("third",d); return d; } var promise=new Promise(function(data,reject){ data(20); console.log("promise body"); }) promise.then(third).then(first).then(second).then(function(res){ console.log("promise call" ,res); });
run
|
edit
|
history
|
help
0
myfirstmodule.js
fast function to reverse unsigned integer
JSON parse
Funny stuff
Range List for JavaScript
Count digits
Accept matching keys in object
localhost:8080/?name=2017&lname=July
demo.js
apply