Skip to Content
자바스크립트 + 리액트 디자인 패턴
book

자바스크립트 + 리액트 디자인 패턴

by 애디 오스마니(Addy Osmani), 윤창식
August 2024
Beginner to intermediate
384 pages
7h 38m
Korean
Hanbit Media, Inc.
Content preview from 자바스크립트 + 리액트 디자인 패턴
218
자바스크립트 + 리액트 디자인 패턴
async function memoizedMakeRequest(url) {
if (cache.has(url)) {
return cache.get(url);
}
const response = await fetch(url);
const data = await response.json();
cache.set(url, data);
return data;
}
9.4.7
비동기 이벤트 처리
비동기 이벤트 처리
async
Event
Handling
패턴은 비동기 함수를 사용하여 이벤트를 처리할 수 있도
록 합니다.
const button = document.querySelector("button");
async function handleClick() {
const response = await makeRequest("http://example.com/");
console.log(response);
}
button.addEventListener("click", handleClick);
9.4.8
async
/
await
파이프라인
async
/
await
파이프라인
async
/
await
Pipeline
패턴은
async
/
await
와 함수형 프로그래밍 기법을
활용하여 비동기 변환 작업들의 파이프라인을 생성합니다.
async function transform1(data) ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

AI를 위한 필수 수학

AI를 위한 필수 수학

할라 넬슨
클라우드 엔지니어를 위한 97가지 조언

클라우드 엔지니어를 위한 97가지 조언

Emily Freeman, Nathen Harvey, 정기훈(Jung Ki Hun)

Publisher Resources

ISBN: 9791169212571