{"id":28089286,"url":"https://github.com/lukeed/preact-offline","last_synced_at":"2025-09-16T12:24:18.138Z","repository":{"id":57329524,"uuid":"113558022","full_name":"lukeed/preact-offline","owner":"lukeed","description":"A (300b gzip) component to render alerts/messages when offline.","archived":false,"fork":false,"pushed_at":"2017-12-08T09:41:20.000Z","size":6,"stargazers_count":29,"open_issues_count":0,"forks_count":1,"subscribers_count":2,"default_branch":"master","last_synced_at":"2025-04-24T22:15:07.197Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"https://jsfiddle.net/lukeed/8at2tg1e/","language":"JavaScript","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/lukeed.png","metadata":{"files":{"readme":"readme.md","changelog":null,"contributing":null,"funding":null,"license":"license","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2017-12-08T09:39:37.000Z","updated_at":"2019-12-09T17:08:42.000Z","dependencies_parsed_at":"2022-09-14T18:40:28.201Z","dependency_job_id":null,"html_url":"https://github.com/lukeed/preact-offline","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukeed%2Fpreact-offline","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukeed%2Fpreact-offline/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukeed%2Fpreact-offline/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/lukeed%2Fpreact-offline/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/lukeed","download_url":"https://codeload.github.com/lukeed/preact-offline/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":253948336,"owners_count":21988953,"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":[],"created_at":"2025-05-13T12:55:58.976Z","updated_at":"2025-09-16T12:24:13.106Z","avatar_url":"https://github.com/lukeed.png","language":"JavaScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# preact-offline [![NPM](https://img.shields.io/npm/v/preact-offline.svg)](https://www.npmjs.com/package/preact-offline)\n\n\u003e A (300b gzip) component to render alerts/messages when offline.\n\nCheck out the [live demo](https://jsfiddle.net/lukeed/8at2tg1e/)!\n\nThis module exposes three module definitions:\n\n* **ES Module**: `dist/preact-offline.es.js`\n* **CommonJS**: `dist/preact-offline.js`\n* **UMD**: `dist/preact-offline.min.js`\n\nIf using the UMD bundle, the library is exposed as `preactOffline` globally.\n\n## Install\n\n```\n$ npm install --save preact-offline\n```\n\n## Usage\n\n```js\nimport { h } from 'preact';\nimport Offline from 'preact-offline';\n\n\u003cOffline /\u003e\n//=\u003e \u003cdiv\u003eNo connection\u003c/div\u003e\n\n\u003cOffline id=\"foo\" class=\"bar\"\u003e\n  \u003cp\u003eCustom Text\u003c/p\u003e\n\u003c/Offline\u003e\n//=\u003e \u003cdiv id=\"foo\" class=\"bar\"\u003e\u003cp\u003eCustom Text\u003c/p\u003e\u003c/div\u003e\n```\n\n## License\n\nMIT © [Luke Edwards](https://lukeed.com)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flukeed%2Fpreact-offline","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Flukeed%2Fpreact-offline","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Flukeed%2Fpreact-offline/lists"}