저 많은 사람 중에 '나'

    async / await

    모던 자바스크립트 딥다이브를 공부한 내용입니다. async / await ES8에서는 비동기 처리를 동기 처리처럼 동작하도록 구현할 수 있는 async/await가 도입되었다. async/await 는 프로미스를 기반으로 동작한다. const fetch = require('node-fetch'); async function fetchTodo() { const url = 'https://jsonplaceholder.typicode.com/todos/1'; const response = await fetch(url); const todo = await response.json(); console.log(todo); // {userId: 1, id: 1, title: 'delectus aut autem', c..