Progressive Web Apps with React

Scott Domes

  • 出版商: Packt Publishing
  • 出版日期: 2017-10-23
  • 售價: $1,970
  • 貴賓價: 9.5$1,872
  • 語言: 英文
  • 頁數: 302
  • 裝訂: Paperback
  • ISBN: 1788297555
  • ISBN-13: 9781788297554
  • 相關分類: React
  • 海外代購書籍(需單獨結帳)

相關主題

商品描述

Key Features

  • Bring the best of mobile sites and native apps to your users with progressive web applications
  • Create fast, reliable, and engaging PWAs with React and Firebase
  • Create high-performance applications even with low connection speeds by leveraging modern web technologies

Book Description

For years, the speed and power of web apps has lagged behind native applications. Progressive Web Apps (PWAs) aim to solve this by bridging the gap between the web apps and native apps, delivering a host of exciting features. Simultaneously, React is fast becoming the go-to solution for building modern web UIs, combining ease of development with performance and capability. Using React alongside PWA technology will make it easy for you to build a fast, beautiful, and functional web app.

After an introduction and brief overview of the goals of PWAs, the book moves on to setting up the application structure. From there, it covers the Webpack build process and the process of creating React components. You'll learn how to set up the backend database and authentication solution to communicate with Firebase and how to work with React Router. Next, you will create and configure your web app manifest, making your PWA installable on mobile devices. Then you'll get introduced to service workers and see how they work as we configure the app to send push notifications using Firebase Cloud Messaging. We'll also explore the App Shell pattern, a key concept in PWAs and look at its advantages regarding efficient performance. Finally, you'll learn how to add offline capabilities to the app with caching and confirm your progress by auditing your PWA with Lighthouse. Also, you'll discover helper libraries and shortcuts that will help you save time and understand the future of PWA development.

What you will learn

  • Set up Webpack configuration, as well as get the development server running
  • Learn basic Firebase configuration and deployment
  • Create routes, manage multiple components, and learn how to use React Router v4 to manage the flow of data
  • Use React life cycle methods to load data
  • Add a service worker to the app and learn how it works
  • Use a service worker to send Push Notifications
  • Configure Webpack to split up the JavaScript bundle and lazy load component files
  • Learn how to use the web Cache API to use your app offline
  • Audit PWAs with Google's Lighthouse tool

About the Author

Scott Domes is a full stack developer who specializes in React, with a passion for building powerful and performant web applications, and for playing with shiny new technologies. Based out of Vancouver, when not coding he's probably out hiking some mountain, or getting lost in a good book. Scott loves to teach and talk about web development, and is always looking to learn new things.

Table of Contents

  1. Creating Our App Structure
  2. Getting Started with Webpack
  3. Our App’s Login Page
  4. Easy Back-End Setup With Firebase
  5. Routing with React
  6. Completing Our App
  7. Making Our App Installable with a Manifest
  8. Adding a Service Worker
  9. Using a Service Worker to Send Push Notifications
  10. The App Shell
  11. Chunking JavaScript to Optimize Performance with Webpack
  12. Ready to Cache
  13. Auditing Our App
  14. Conclusion & Next Steps

商品描述(中文翻譯)

關鍵特點
- 透過漸進式網頁應用程式(PWA)將最佳的行動網站和原生應用程式帶給用戶
- 使用 React 和 Firebase 創建快速、可靠且引人入勝的 PWA
- 利用現代網頁技術,即使在低連接速度下也能創建高效能的應用程式

書籍描述
多年來,網頁應用程式的速度和效能一直落後於原生應用程式。漸進式網頁應用程式(PWAs)旨在通過彌合網頁應用程式和原生應用程式之間的差距,提供一系列令人興奮的功能。同時,React 正迅速成為構建現代網頁用戶介面的首選解決方案,結合了開發的便利性、效能和功能。使用 React 與 PWA 技術將使您能輕鬆構建快速、美觀且功能強大的網頁應用程式。

在介紹和簡要概述 PWA 的目標後,本書將進入應用程式結構的設置。接著,將涵蓋 Webpack 的構建過程和創建 React 組件的過程。您將學習如何設置後端數據庫和身份驗證解決方案,以便與 Firebase 通信,以及如何使用 React Router。接下來,您將創建和配置網頁應用程式清單,使您的 PWA 可以在行動設備上安裝。然後,您將了解服務工作者,並看到它們如何運作,因為我們配置應用程式以使用 Firebase Cloud Messaging 發送推播通知。我們還將探索 App Shell 模式,這是 PWA 的一個關鍵概念,並查看其在效能效率方面的優勢。最後,您將學習如何通過快取為應用程式添加離線功能,並通過使用 Lighthouse 審核您的 PWA 來確認您的進展。此外,您將發現一些輔助庫和捷徑,幫助您節省時間並了解 PWA 開發的未來。

您將學習的內容
- 設置 Webpack 配置,並啟動開發伺服器
- 學習基本的 Firebase 配置和部署
- 創建路由,管理多個組件,並學習如何使用 React Router v4 管理數據流
- 使用 React 生命週期方法加載數據
- 為應用程式添加服務工作者並了解其運作方式
- 使用服務工作者發送推播通知
- 配置 Webpack 以拆分 JavaScript 包並延遲加載組件文件
- 學習如何使用網頁快取 API 使您的應用程式離線可用
- 使用 Google 的 Lighthouse 工具審核 PWA

關於作者
Scott Domes 是一位全端開發者,專注於 React,熱衷於構建強大且高效能的網頁應用程式,並喜愛玩弄新技術。居住在溫哥華,當不在編碼時,他可能會在某座山上健行,或沉浸在一本好書中。Scott 喜歡教學和討論網頁開發,並始終尋求學習新事物。

目錄
1. 創建我們的應用程式結構
2. 開始使用 Webpack
3. 我們應用程式的登入頁面
4. 使用 Firebase 進行簡易後端設置
5. 使用 React 進行路由
6. 完成我們的應用程式
7. 通過清單使我們的應用程式可安裝
8. 添加服務工作者
9. 使用服務工作者發送推播通知
10. 應用程式外殼
11. 使用 Webpack 將 JavaScript 拆分以優化效能
12. 準備快取
13. 審核我們的應用程式
14. 結論與後續步驟