chore: update readme w/ badges

This commit is contained in:
Ayo Ayco 2024-08-03 11:41:35 +02:00
parent 8489d3cc17
commit 048cc69113

View file

@ -2,6 +2,11 @@
# Astro SW # Astro SW
[![Package information: NPM version](https://img.shields.io/npm/v/@ayco/astro-sw)](https://www.npmjs.com/package/@ayco/astro-sw)
[![Package information: NPM license](https://img.shields.io/npm/l/@ayco/astro-sw)](https://www.npmjs.com/package/@ayco/astro-sw)
[![Package information: NPM downloads](https://img.shields.io/npm/dt/@ayco/astro-sw)](https://www.npmjs.com/package/@ayco/astro-sw)
[![Bundle Size](https://img.shields.io/bundlephobia/minzip/@ayco/astro-sw)](#library-size)
The integration `serviceWorker` accepts configuration with service worker path and automatically injects needed dynamic variables such as `assets` generated by Astro for caching The integration `serviceWorker` accepts configuration with service worker path and automatically injects needed dynamic variables such as `assets` generated by Astro for caching
## Installation ## Installation
@ -51,4 +56,4 @@ The integration accepts a configuration object of type `ServiceWorkerConfig` wit
## Example sw.js ## Example sw.js
You can find an example service worker (`example_sw.js`) in the [repository](https://ayco.io/gh/astro-sw), and here's the [raw file](https://raw.githubusercontent.com/ayoayco/astro-sw/main/example_sw.js) too. You can find an example service worker (`example_sw.js`) in the [repository](https://ayco.io/gh/astro-sw), and here's the [raw file](https://raw.githubusercontent.com/ayoayco/astro-sw/main/example_sw.js) too.