Skip to content

Commit

Permalink
Initial commit
Browse files Browse the repository at this point in the history
  • Loading branch information
birtles committed Jul 12, 2024
0 parents commit 9132588
Show file tree
Hide file tree
Showing 24 changed files with 5,269 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
name: Automated checks
on: [push]

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4.1.7

- name: Install pnpm
uses: pnpm/action-setup@v4
with:
version: latest

- uses: actions/setup-node@v4.0.2
with:
cache: pnpm
node-version: 20

- name: Build
run: |
pnpm install
pnpm build
- name: Knip
run: pnpm knip

- name: Prettier
run: pnpm prettier --check src "*.{ts,json,md}"
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
dist/
node_modules/
1 change: 1 addition & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
pnpm lint-staged
23 changes: 23 additions & 0 deletions .release-it.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
{
"git": {
"commitMessage": "chore: release v${version}",
"requireBranch": "main",
"tagName": "v${version}"
},
"github": {
"release": true,
"comments": {
"submit": true
}
},
"npm": {
"publishArgs": ["--provenance"]
},
"plugins": {
"@release-it/conventional-changelog": {
"preset": "conventionalcommits",
"infile": "CHANGELOG.md",
"header": "# Changelog"
}
}
}
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# Changelog
12 changes: 12 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# `@birchill/inject-manifest-plugin`

An rspack plugin that generates a manifest for injecting into a service worker.
Based on the `InjectManifestPlugin` part of the
[`workbox-webpack-plugin`](https://github.com/GoogleChrome/workbox/) package
but adapted to rspack.

## Usage

```js
// TODO
```
4 changes: 4 additions & 0 deletions knip.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
{
"entry": ["src/index.ts"],
"ignore": ["tsup.config.ts"]
}
58 changes: 58 additions & 0 deletions package.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{
"name": "@birchill/inject-manifest-plugin",
"version": "0.1.0",
"description": "rspack plugin to inject a manifest file into a service worker file",
"repository": "https://github.com/birchill/inject-manifest-plugin/",
"keywords": [
"service worker",
"manifest"
],
"author": "Birchill, Inc.",
"license": "MIT",
"type": "module",
"main": "dist/index.js",
"files": [
"dist/**"
],
"publishConfig": {
"registry": "https://registry.npmjs.org"
},
"dependencies": {
"fast-json-stable-stringify": "^2.1.0",
"pretty-bytes": "^6.1.1",
"schema-utils": "^4.2.0",
"webpack-sources": "^3.2.3"
},
"devDependencies": {
"@release-it/conventional-changelog": "8.0.1",
"@rspack/core": "1.0.0-alpha.3",
"@types/node": "20.14.10",
"@types/webpack-sources": "3.2.3",
"husky": "9.0.11",
"knip": "5.25.2",
"lint-staged": "15.2.7",
"prettier": "3.3.2",
"release-it": "17.5.0",
"tsup": "8.1.0",
"typescript": "5.5.3"
},
"peerDependencies": {
"@rspack/core": "^1.0.0-alpha.3"
},
"scripts": {
"preinstall": "npx only-allow pnpm",
"prepublishOnly": "pnpm build",
"build": "tsup",
"release": "release-it",
"prepare": "husky"
},
"prettier": {
"singleQuote": true,
"trailingComma": "es5"
},
"lint-staged": {
"*.{ts,json}": [
"prettier --write"
]
}
}
Loading

0 comments on commit 9132588

Please sign in to comment.