자바스크립트 비동기 프로그래밍 2편
*Udemy의 The Complete JavaScript Course 2020: Build Real Projects! 참고 1.PROMISE const getIDs = new Promise((resolve, reject) => { setTimeout(() => { resolve([523, 883, 432, 974]); }, 1500); }); const getRecipe = (recID) => { return new Promise((resolve, reject) => { setTimeout( (ID) => { const recipe = { title: "Fresh tomato pasta", publisher: "Jonas" }; resolve(`${ID}: ${recipe.title}`); }, 1500..
JavaScript
2020. 8. 7. 17:09