This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
function 사용자이름정보출력하기() { // | |
var user = 사용자id로정보조회(api); | |
if (user.id === 1) { | |
console.log(user.name); | |
} | |
} | |
*/ | |
async function 사용자이름정보출력하기() { |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
$.get('url', function(response) { | |
자리를리턴하는함수(response, function(id) { | |
앉았는지를확인하는함수 (id, function(result) { // | |
음식을리턴하는함수(result, function(text) { | |
console.log(text); | |
}); | |
}); | |
}); | |
}); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// https://joshua1988.github.io/web-development/javascript/javascript-asynchronous-operation/ | |
// #1 | |
console.log('Hello'); | |
// #2 | |
setTimeout(function() { | |
console.log('Bye'); | |
}, 3000); | |
// #3 | |
console.log('Hello Again'); |