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

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

by 한민주, 양찬석, 탈 아터
April 2019
Beginner to intermediate
368 pages
7h 18m
Korean
Hanbit Media, Inc.
Content preview from 만들면서 배우는 프로그레시브 웹 앱: 사용자 경험을 극대화하는 차세대 웹 앱 기술
270 - 프로그레시브 웹 앱
10.1
푸시 알림의 생애
1
장에서부터 푸시 알림에 대해 이야기해왔습니다. 이 시점에서 푸시 알림에 대해
한 가지 짚고 넘어가야 것이 있습니다.
푸시 알림은 실제로는 ‘한 가지’로 이루어지지 않았습니다.
푸시 알림은
Push API
를 사용하여 전송된 ‘메시지’와
Notification API
를 사용하
여 보여지는 ‘알림’의 두 가지 기능으로 이루어져 있습니다.
10
.
1
.
1
Notification
API
Notification
API
를 사용하면 웹페이지나 서비스 워커가 시스템 알림을 생성하
고 표시할 수 있습니다.
이러한 알림은 브라우저 밖
(
기기 상의
UI)
에 표시되며, 단일 브라우저 윈도우나 탭
컨텍스트 외부에 존재합니다. 알림은 브라우저 윈도우나 탭과는 독립적으로 작동
하기 때문에, 사용자가 사이트를 떠난 후에도 생성될 수 있습니다.
사용자에게 알림을 표시하기 전에 우선 사용자에게 권한을 요청해야 합니다.
다음 코드 예제에서 보는 것과 같이 이 과정은 비교적 간단합니다.
Notification
.
requestPermission
().
then
(
function
(
permission
)
{
if
(
permission
===
"
granted
")
{
new Notification
("
Shiny
");
}
});
알림 표시 권한을 요청하는 것은 이 샘플 ...
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