monsoonconsulting/magento2-pwa
Composer 安装命令:
composer require monsoonconsulting/magento2-pwa
包简介
Adds a service worker to Magento2 to enable PWA features.
README 文档
README
Adds icons, a web manifest file and a service-worker file to make magento 2 a PWA.
Installation
composer require monsoonconsulting/magento2-pwa
Main Features
- Supports Magento Blank and Luma as well as Hyvä based themes.
⚠️ Hyvä is recommended to ensure fast performance.


- Makes Magento Installable as a PWA.
- A CMS Page can be configured for an offline page.
- Add to Home screen prompt
- Enable/Disable Offline Google Analytics.
- Utilises the Browser's Cache API.
- Service worker lifecycle management.
Configuration
To configure the module go to Stores > Configuration > Monsoon > PWA.

Offline Page
In Stores > Configuration > Monsoon > PWA select the page you wish to use as your offline notification page. Alternatively use the default one provided by this module.
Customisation
In your Magento theme, override the images and PWA app details found in:
- Monsoon/Pwa/view/frontend/web/images/favicons
- Monsoon/Pwa/view/frontend/web/manifest.icon
For generating the correct icons there are useful tools such as a favicon generator and maskable icon editor.
Configure Service Worker
Most PWA features can be adjusted/added in the service-worker file.
- Simply override
Monsoon_Pwa/view/frontend/templates/service-worker.js.phtmlin your theme to customise.
OR - To extend add your custom JavaScript to a PHTML file and add it to the service worker via
Magento's LayoutXML in, by extending the
serviceworker_index_js.xmlfile to include your code.
monsoonconsulting/magento2-pwa 适用场景与选型建议
monsoonconsulting/magento2-pwa 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 23.24k 次下载、GitHub Stars 达 23, 最近一次更新时间为 2021 年 07 月 07 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 monsoonconsulting/magento2-pwa 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 monsoonconsulting/magento2-pwa 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 23.24k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 23
- 点击次数: 14
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: GPL-3.0-only
- 更新时间: 2021-07-07