Skip to Content
만들면서 배우는 프로그레시브 웹 앱: 사용자 경험을 극대화하는 차세대 웹 앱 기술
book

만들면서 배우는 프로그레시브 웹 앱: 사용자 경험을 극대화하는 차세대 웹 앱 기술

by 한민주, 양찬석, 탈 아터
April 2019
Beginner to intermediate
368 pages
7h 18m
Korean
Hanbit Media, Inc.
Content preview from 만들면서 배우는 프로그레시브 웹 앱: 사용자 경험을 극대화하는 차세대 웹 앱 기술
212 - 프로그레시브 웹 앱
만 기존 웹 앱에서 백그라운드 동기화를 구현하는 것은 그렇게 간단하지 않습니
다. 다음 섹션에서는 우리 프로젝트에서 백그라운드 동기화를 어떻게 다룰 것인지
살펴볼 예정입니다.
백그라운드 동기화를 지원하는 브라우저
백그라운드 동기화는 크롬
49
버전부터 사용 가능했습니다.
이 책을 집필 시점을 기준으로 오페라, 모질라 파이어폭스, 마이크로소프트 엣지 브
라우저에서도 사용 가능합니다.
7.3
동기화 이벤트로 데이터 넘기기
작업을 수행하는 코드를 페이지에서 서비스 워커로 옮기면, 무슨 일이 있어도
작업이 수행되도록 만들 수 있습니다. 하지만 이로 인해 새로운 복잡성이 생겨
납니다.
대부분의 경우 페이지에서 수행되는 작업을 완료되기 위해서는 데이터가 필요합
니다. 메시지를 전송하는 함수를 호출하는 페이지는 메시지 텍스트가 필요합니
다. 포스팅에 ‘좋아요’를 누르는 함수는 포스팅의
ID
가 필요합니다. 하지만 동기
화 이벤트를 등록할 때는 이벤트 이름만 전달할 수 있습니다. 다시 말해 백그라운
드에서 메시지를 전송하도록 서비스 워커에 요청할 수는 있지만, 메시지 텍스트를
전달하는 것은 함수에 인자를 전달하는 것처럼 간단하지 않습니다.
이를 해결하기 위해 다양한 방법이 존재합니다. 그중 세 가지 방법을 소개해 보겠
습니다.
7
.
3
.
1
IndexedDB
에 액션 ...
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.

Read now

Unlock full access

More than 5,000 organizations count on O’Reilly

AirBnbBlueOriginElectronic ArtsHomeDepotNasdaqRakutenTata Consultancy Services

QuotationMarkO’Reilly covers everything we've got, with content to help us build a world-class technology community, upgrade the capabilities and competencies of our teams, and improve overall team performance as well as their engagement.
Julian F.
Head of Cybersecurity
QuotationMarkI wanted to learn C and C++, but it didn't click for me until I picked up an O'Reilly book. When I went on the O’Reilly platform, I was astonished to find all the books there, plus live events and sandboxes so you could play around with the technology.
Addison B.
Field Engineer
QuotationMarkI’ve been on the O’Reilly platform for more than eight years. I use a couple of learning platforms, but I'm on O'Reilly more than anybody else. When you're there, you start learning. I'm never disappointed.
Amir M.
Data Platform Tech Lead
QuotationMarkI'm always learning. So when I got on to O'Reilly, I was like a kid in a candy store. There are playlists. There are answers. There's on-demand training. It's worth its weight in gold, in terms of what it allows me to do.
Mark W.
Embedded Software Engineer

You might also like

파이썬으로 웹 크롤러 만들기: 초간단 나만의 웹 크롤러로 원하는 데이터 가져오는 방법

파이썬으로 웹 크롤러 만들기: 초간단 나만의 웹 크롤러로 원하는 데이터 가져오는 방법

한선용, 라이언 미첼

Publisher Resources

ISBN: 9791162248737