preface
I first came into contact with PWA at the beginning of 2017, when I attended a front-end sharing session. One of the topics was PWA-related, which introduced PWA’s Service Worker and its ability to install on the desktop, as well as the future development trend of this technology. After listening to this sharing, I was attracted by some capabilities of PWA.
Advantage of the Web itself is very obvious, such as share, search, do not need to download, have the same show on any device, etc., coupled with the ability of PWA, now let the Web on the basis of the original with the kind of the function of the native applications, this is a boon for Web developers, can let the Web to provide a better user experience, It also pays more dividends. Then, I began to study and explore PWA.
In practical work, there are many scenarios suitable for the use of PWA, which gives me a good prerequisite for the path of PWA practice. In the process of practice, it did not go as smoothly as expected. Most of the CONCEPTS of PWA have some understanding costs, and if you are not careful, you may make mistakes. In most cases, you “dig holes” and “fill holes” at the same time. Of course, in the end, in many appropriate scenarios, I found that PWA access did bring very good results, adding more value to the business product and improving the user experience.
This book is an introduction to PWA technology and practice book. Through this book, you can gain a deeper understanding of PWA and do some hands-on projects. This book makes a thorough explanation of the core technology of PWA, and also fully explains the problems that may be encountered in PWA and some matters needing attention. During the reading process, all the PWA knowledge points can be found in this book. This book can be used as both a PWA primer and a PWA manual. When you have a problem with PWA, please read this book. I believe this book will help you find a solution to your problem.
Chapter 1 introduces the history and ecology of PWA, and introduces you to the first PWA application example to give you a basic understanding of PWA. Chapter 2 introduces some of the techniques and preconditions of PWA to make your learning process smoother. If you already know this part, you may want to skip this chapter. Chapter 3 begins to explain the most core part of PWA — Service Worker. This chapter explains various knowledge points, matters needing attention and practices of Service Worker in detail. Chapter 4 begins with the core API of PWA. In this chapter, you can learn some core APIS of PWA, including installation to desktop, next generation network request, message notification, background synchronization, offline cache, and message push. Each section of this chapter is parallel knowledge, and you can read any section according to your needs. Chapter 5 introduces some of the tools you can use to make your PWA development process smoother, including debugging tools, evaluation tools, and performance enhancement tools. Chapter 6 is the practice part of PWA, which explains the practice of different functional requirements. Chapter 7 explains the Web’s system integration capabilities, which match PWA to make the Web comparable to applications. The book is aimed at those who have some foundation in Web development, as well as developers who want to learn about PWA or need a comprehensive PWA manual.
The preface
Nowadays, the Internet traffic has already entered the mobile terminal, and the mobile terminal traffic of domestic mainstream Internet products has generally exceeded 80% of the overall traffic. In mobile app development, we face the problem of developing apps for different operating systems (Android, iOS, Windows 10) and different devices (phones, tablets), and we have to pay extra to accommodate these differences. Even with the investment and development of the product, there is still a huge distribution cost in downloading and installing the product. Statistical studies show that cumbersome installation is one of the main reasons users give up trying more apps.
PWA technology can solve these problems well. PWA extends and enhances the Web with modern Web API capabilities, making the Web experience and capabilities similar to those of native applications. As a W3C specification implementation, PWA works well in browsers across all platforms, and is truly a set of code that solves all platform consistency issues. Also, because PWA has a near-zero installation cost, it is ideal for the transition from Web to application, increasing conversion rates.
At present, more and more websites at home and abroad have access to PWA, such as Starbucks, Uber, Twitter, Facebook, Taobao, Ele. me, etc., and the performance and conversion rate have been significantly improved after access. Nowadays, Google, Microsoft, Intel and other companies have invested in the technical support and development of PWA. Mainstream Web frameworks such as React and Vue provide fast access solutions to PWA. Mainstream browser manufacturers also follow closely to jointly support the PWA ecosystem.
However, based on my observations of the domestic industry and front-end community in recent years, I can say that PWA has not yet played its role in China. Here, I try to analyze why, and what the future holds.
First, in the past three years at least, in addition to following the latest trends of foreign countries, the general trend is that technology with strong business attributes is paid more attention to. Among them, the most eye-catching technologies related to small programs and technologies related to low code construction are typical, which respectively meet the realistic needs of domestic leading Internet companies for strong control of traffic distribution and the background of China’s Internet industry gradually shifting to enterprise services.
PWA neutrality as a strong combination, despite a major push by Google, but the openness and the main focus is on optimization experience rather than specific products to meet the demands of the business characteristic, caused it to a major push by community at home, the volume is clearly commercial impetus strong technology, is in a “you need, They don’t realize that other people are taking what they want.”
Faced with this situation, as technologists, we should treat it rationally, rather than unilaterally affirm or deny a technology like some followers. As a matter of fact, AS a combination of progressive technologies, PWA has long been widely used in China due to its strong practicability, such as Service Worker, offline storage, and even Lighthouse, a performance evaluation tool.
Second, the landing of an engineering technology, in addition to the principle demonstration and the verification of various function points and performance indicators, also needs a very high cost of the “pit” process. This is not to find one or two interns through Demo to do a Demo can solve, but need real experience, which includes both the implementation details, performance optimization and technology measure, in the face of the domestic special scenario techniques such as the accumulation of knowledge, and development, operations, data statistics and so on the development of the necessary infrastructure on the link and the accumulation of experience.
There has always been a lack of quality and reliable Technical data in Chinese in the PWA field. On the one hand, the research teams refer directly to official documents, on the other hand, they can only obtain some scattered information through unreliable channels such as various technical blogs, and accumulate experience through piecing together and trying, which virtually pushes up the cost of technical research.
And the book you’re looking at could be a good place to start. As the first Chinese PWA technology book in my field of vision, the advantage of this book lies in that it is not a document translation, nor is it a “recipe” for development technology, but a “full link book” covering theoretical preparation, practical operation process, and experience sharing. It will help you to really understand PWA and gain some hands-on experience with the “pothole” of a project landing. From this perspective, this book can be called “PWA Folk Guide to Chinese”, with which we finally have some solid, systematic, localized, out-of-the-box PWA technology assets.
Third, PWA is positioned to allow developers to quickly develop products with both “quality Web and lightweight applications” attributes. Such attributes, in the extensive development of the Internet business, has not been due attention.
However, things are changing.
In an era when everyone is talking about the “second half of the Internet,” it’s important to think about what that “second half” actually means for us. My personal understanding is that the so-called first half, than people have no I have, people slow me fast; In the second half, it was better than me, and WE are now witnessing such a market shift. PWA, as a technology to significantly improve user experience, is bound to show its advantages in this process. Whoever can make use of this advantage faster and better will take the lead in the competition of front-end technology in the new stage.
To sum up, this is a book worth looking forward to, which to some extent fills the gap of technical books in the field of PWA in China, and accomplishes the task quite beautifully. If I had been asked to share a list of books on front-end technology, THIS would have been one of them.
— Lisangeng, a well-known technical author of Zhihu, was held in Hangzhou in April 2020
Buy address
Welcome to purchase support ~~
Dangdang purchase
Jingdong buy
Tmall purchase