{"id":21931759,"url":"https://github.com/lekoala/silverstripe-pwa","last_synced_at":"2025-10-18T17:30:09.364Z","repository":{"id":63999735,"uuid":"570620104","full_name":"lekoala/silverstripe-pwa","owner":"lekoala","description":"PWA support in SilverStripe","archived":false,"fork":false,"pushed_at":"2025-03-28T14:07:00.000Z","size":45,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-03-28T15:22:44.838Z","etag":null,"topics":["module","push","push-notifications","pwa","silverstripe"],"latest_commit_sha":null,"homepage":"","language":"PHP","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/lekoala.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":".github/FUNDING.yml","license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null},"funding":{"github":"lekoala"}},"created_at":"2022-11-25T16:29:17.000Z","updated_at":"2025-03-28T14:07:03.000Z","dependencies_parsed_at":"2024-02-16T12:25:00.496Z","dependency_job_id":"5c250252-e346-44fc-b664-31cd04971cb4","html_url":"https://github.com/lekoala/silverstripe-pwa","commit_stats":{"total_commits":12,"total_committers":1,"mean_commits":12.0,"dds":0.0,"last_synced_commit":"d9f8bb8d18bb2fd4f51e8e4dc78cf262b1cf35c5"},"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lekoala%2Fsilverstripe-pwa","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lekoala%2Fsilverstripe-pwa/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lekoala%2Fsilverstripe-pwa/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lekoala%2Fsilverstripe-pwa/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lekoala","download_url":"https://codeload.github.com/lekoala/silverstripe-pwa/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":249777396,"owners_count":21324084,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["module","push","push-notifications","pwa","silverstripe"],"created_at":"2024-11-28T23:14:56.439Z","updated_at":"2025-10-18T17:30:04.299Z","avatar_url":"https://github.com/lekoala.png","language":"PHP","funding_links":["https://github.com/sponsors/lekoala"],"categories":[],"sub_categories":[],"readme":"# SilverStripe Pwa module\n\n![Build Status](https://github.com/lekoala/silverstripe-pwa/actions/workflows/ci.yml/badge.svg)\n[![scrutinizer](https://scrutinizer-ci.com/g/lekoala/silverstripe-pwa/badges/quality-score.png?b=master)](https://scrutinizer-ci.com/g/lekoala/silverstripe-pwa/)\n[![Code coverage](https://codecov.io/gh/lekoala/silverstripe-pwa/branch/master/graph/badge.svg)](https://codecov.io/gh/lekoala/silverstripe-pwa)\n\n## Features\n\n-   Support push notifications\n-   Generate a valid manifest\n-   Provides a default configurable service worker that can cache assets\n\n## Generate icons\n\nUse the cli `npm run generate-assets(-root)` (if you have a `app/images/logo.svg` file) or upload a zip file with the required icons\n\nNote: pay attention to [maskable icons](https://web.dev/maskable-icon/). You can test their\nsize in the developer console. You can test them in [maskable.app](https://maskable.app/)\n\n## Subscribe to push notifications\n\nclient.js provides some base code for this. You need to put somewhere a checkbox that can be used\nto toggle push notifications on/off.\n\n```html\n\u003clabel\u003e\u003cinput type=\"checkbox\" class=\"js-push-toggle\" /\u003e Enable notifications\u003c/label\u003e\n```\n\nThis is dealt with by client.js. You can replace client code by your custom code or disable it entirely\n\n```yml\nLeKoala\\SsPwa\\ServiceWorkerController:\n  enable_client_js: false\n  custom_client_path: \"/my/custom/path\"\n```\n\n## Service worker\n\nThis module provides a default service worker. You can use your own if needed\n\n```yml\nLeKoala\\SsPwa\\ServiceWorkerController:\n  custom_sw_path: \"/my/custom/path\"\n```\n\n## Use vapid keys\n\nYou can generate the vapid keys with this [online tool](https://tools.reactpwa.com/vapid) or with the cli `npm run gen-push-keys`\n\nYou need to save them either in your .env file or as YML config.\n\n```\nPUSH_PUBLIC_KEY='BK1Zt63e94HgYNm-s9aquI85AUdDRz3uKMxue7woQVZv0_3txywXPgyYd2WPJetayKYq3E_AObBGD9rHWOL_...'\nPUSH_PRIVATE_KEY='1nKKQnzGRMNit-TuvklqoTY_ENO8eAybp1MsZWx0...'\n```\n\n## Sending push notifications\n\nYou can use the following piece of code\n\n```php\nPushSubscription::sendPushNotifications($where, $data);\n```\n\n## Credits\n\nThanks to https://github.com/a2nt/silverstripe-progressivewebapp for some inspiration :-)\n\n## Compatibility\n\nTested with ^5\n\n## Maintainer\n\nLeKoala - thomas@lekoala.be\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flekoala%2Fsilverstripe-pwa","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flekoala%2Fsilverstripe-pwa","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flekoala%2Fsilverstripe-pwa/lists"}