# cra-replace-service-worker

> Replaces Create React App's service worker with you own service worker without ejecting. This package also adds a variable 'PRECACHE_FILES' to your custom service worker. It contains a list of file-paths to all CRA files generated inside the 'build'-folde

Latest version **0.0.8** (published 2018-08-13) · MIT license · 0 weekly downloads

## Install

```sh
npm install cra-replace-service-worker
pnpm add cra-replace-service-worker
yarn add cra-replace-service-worker
bun add cra-replace-service-worker
```

Provides the command `cra-replace-service-worker`.

## Health

**Score 15/100 (F)** — status: abandoned.

Positive: no vulnerabilities.

Warnings: low downloads; no types; no esm support; pre 1.0.

Negative: abandoned; low maintenance score.

## Facts

| | |
|---|---|
| Version | 0.0.8 |
| Published | 2018-08-13 |
| First published | 2018-08-08 |
| Weekly downloads | 0 |
| License | MIT |
| TypeScript types | none |
| Module format | CommonJS |
| Dependencies | 2 |
| Unpacked size | 2.5 KB |
| Known vulnerabilities | 0 |
| Install scripts | no |
| Author | Fredrik Ward |
| Maintainers | fredrik.ward |
| Keywords | 'service worker', 'sw', 'cra', 'create react app' |

## Links

- npm: https://www.npmjs.com/package/cra-replace-service-worker
- npm.io page: https://npm.io/package/cra-replace-service-worker

## Dependencies (2)

- [commander](https://npm.io/package/commander.md) ^2.17.1
- [list-contents](https://npm.io/package/list-contents.md) ^4.0.2

## Alternatives

- [cron](https://npm.io/package/cron.md) — 4.9M weekly downloads
- [@vercel/queue](https://npm.io/package/@vercel/queue.md) — 731.6K weekly downloads
- [create-sonicjs](https://npm.io/package/create-sonicjs.md) — 1.6K weekly downloads
- [@exellix/jobs-api](https://npm.io/package/@exellix/jobs-api.md) — 941 weekly downloads
- [@forwardimpact/libskill](https://npm.io/package/@forwardimpact/libskill.md) — 575 weekly downloads

## Recent versions

- 0.0.8 (latest) — 2018-08-13
- 0.0.7 — 2018-08-09
- 0.0.6 — 2018-08-09
- 0.0.5 — 2018-08-08
- 0.0.4 — 2018-08-08
- 0.0.3 — 2018-08-08
- 0.0.2 — 2018-08-08
- 0.0.1 — 2018-08-08

## README

This package replaces Create React App's service worker with you own service worker without ejecting. This package also adds a variable 'PRECACHE_FILES' to your custom service worker. It contains a list of file-paths to all CRA files generated inside the 'build'-folder.

#Usage#
In your *package.json* under *scripts* add the following:

"replace-sw": "cra-replace-service-worker ./src/your-custom-sw.js"

Enjoy!

---
_Source: https://npm.io/package/cra-replace-service-worker · Machine-readable twin of the npm.io package page. Health data is recomputed on every publish._
