@vite-pwa/vitepress 1.0.0 โ†’ 1.0.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (4) hide show
  1. package/LICENSE +21 -21
  2. package/README.md +90 -90
  3. package/index.d.ts +1 -1
  4. package/package.json +9 -25
package/LICENSE CHANGED
@@ -1,21 +1,21 @@
1
- MIT License
2
-
3
- Copyright (c) 2022-PRESENT Anthony Fu <https://github.com/antfu>
4
-
5
- Permission is hereby granted, free of charge, to any person obtaining a copy
6
- of this software and associated documentation files (the "Software"), to deal
7
- in the Software without restriction, including without limitation the rights
8
- to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
- copies of the Software, and to permit persons to whom the Software is
10
- furnished to do so, subject to the following conditions:
11
-
12
- The above copyright notice and this permission notice shall be included in all
13
- copies or substantial portions of the Software.
14
-
15
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
- IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
- FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
- AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
- LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
- OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
- SOFTWARE.
1
+ MIT License
2
+
3
+ Copyright (c) 2022-PRESENT Anthony Fu <https://github.com/antfu>
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
package/README.md CHANGED
@@ -1,90 +1,90 @@
1
- <p align='center'>
2
- <img src='./hero.png' alt="@vite-pwa/vitepress - Zero-config PWA for VitePress"><br>
3
- Zero-config PWA Plugin for VitePress
4
- </p>
5
-
6
- <p align='center'>
7
- <a href='https://www.npmjs.com/package/@vite-pwa/vitepress' target="__blank">
8
- <img src='https://img.shields.io/npm/v/@vite-pwa/vitepress?color=33A6B8&label=' alt="NPM version">
9
- </a>
10
- <a href="https://www.npmjs.com/package/@vite-pwa/vitepress" target="__blank">
11
- <img alt="NPM Downloads" src="https://img.shields.io/npm/dm/@vite-pwa/vitepress?color=476582&label=">
12
- </a>
13
- <a href="https://vite-pwa-org.netlify.app/frameworks/vitepress" target="__blank">
14
- <img src="https://img.shields.io/static/v1?label=&message=docs%20%26%20guides&color=2e859c" alt="Docs & Guides">
15
- </a>
16
- <br>
17
- <a href="https://github.com/vite-pwa/vitepress" target="__blank">
18
- <img alt="GitHub stars" src="https://img.shields.io/github/stars/vite-pwa/vitepress?style=social">
19
- </a>
20
- </p>
21
-
22
- <br>
23
-
24
- <p align="center">
25
- <a href="https://cdn.jsdelivr.net/gh/antfu/static/sponsors.svg">
26
- <img src='https://cdn.jsdelivr.net/gh/antfu/static/sponsors.svg'/>
27
- </a>
28
- </p>
29
-
30
- ## ๐Ÿš€ Features
31
-
32
- - ๐Ÿ“– [**Documentation & guides**](https://vite-pwa-org.netlify.app/)
33
- - ๐Ÿ‘Œ **Zero-Config**: sensible built-in default configs for common use cases
34
- - ๐Ÿ”ฉ **Extensible**: expose the full ability to customize the behavior of the plugin
35
- - ๐Ÿฆพ **Type Strong**: written in [TypeScript](https://www.typescriptlang.org/)
36
- - ๐Ÿ”Œ **Offline Support**: generate service worker with offline support (via Workbox)
37
- - โšก **Fully tree shakable**: auto inject Web App Manifest
38
- - ๐Ÿ’ฌ **Prompt for new content**: built-in support for Vanilla JavaScript, Vue 3, React, Svelte, SolidJS and Preact
39
- - โš™๏ธ **Stale-while-revalidate**: automatic reload when new content is available
40
- - โœจ **Static assets handling**: configure static assets for offline support
41
- - ๐Ÿž **Development Support**: debug your custom service worker logic as you develop your application
42
- - ๐Ÿ› ๏ธ **Versatile**: integration with meta frameworks: [รฎles](https://github.com/ElMassimo/iles), [SvelteKit](https://github.com/sveltejs/kit), [VitePress](https://github.com/vuejs/vitepress), [Astro](https://github.com/withastro/astro), [Nuxt 3](https://github.com/nuxt/nuxt) and [Remix](https://github.com/remix-run/remix)
43
- - ๐Ÿ’ฅ **PWA Assets Generator**: generate all the PWA assets from a single command and a single source image
44
- - ๐Ÿš€ **PWA Assets Integration**: serving, generating and injecting PWA Assets on the fly in your application
45
-
46
- ## ๐Ÿ“ฆ Install
47
-
48
- > From v0.3, `@vite-pwa/vitepress` requires **Vite 5** and **VitePress 1.0.0-rc.26 or above**.
49
-
50
- > Using any version older than v0.3 requires Vite 3.1.0+.
51
-
52
- ```bash
53
- npm i @vite-pwa/vitepress -D
54
-
55
- # yarn
56
- yarn add @vite-pwa/vitepress -D
57
-
58
- # pnpm
59
- pnpm add @vite-pwa/vitepress -D
60
- ```
61
-
62
- ## ๐Ÿฆ„ Usage
63
-
64
- You will need to wrap your VitePress config with `withPwa`:
65
-
66
- ```ts
67
- // .vitepress/config.ts
68
- import { withPwa } from '@vite-pwa/vitepress'
69
- import { defineConfig } from 'vitepress'
70
-
71
- export default withPwa(defineConfig({
72
- /* your VitePress options */
73
- /* Vite PWA Options */
74
- pwa: {}
75
- }))
76
- ```
77
-
78
- Read the [๐Ÿ“– documentation](https://vite-pwa-org.netlify.app/frameworks/vitepress) for a complete guide on how to configure and use
79
- this plugin.
80
-
81
- ## ๐Ÿ‘€ Full config
82
-
83
- Check out the type declaration [src/types.ts](./src/types.ts) and the following links for more details.
84
-
85
- - [Web app manifests](https://developer.mozilla.org/en-US/docs/Web/Manifest)
86
- - [Workbox](https://developers.google.com/web/tools/workbox)
87
-
88
- ## ๐Ÿ“„ License
89
-
90
- [MIT](./LICENSE) License &copy; 2022-PRESENT [Anthony Fu](https://github.com/antfu)
1
+ <p align='center'>
2
+ <img src='./hero.png' alt="@vite-pwa/vitepress - Zero-config PWA for VitePress"><br>
3
+ Zero-config PWA Plugin for VitePress
4
+ </p>
5
+
6
+ <p align='center'>
7
+ <a href='https://www.npmjs.com/package/@vite-pwa/vitepress' target="__blank">
8
+ <img src='https://img.shields.io/npm/v/@vite-pwa/vitepress?color=33A6B8&label=' alt="NPM version">
9
+ </a>
10
+ <a href="https://www.npmjs.com/package/@vite-pwa/vitepress" target="__blank">
11
+ <img alt="NPM Downloads" src="https://img.shields.io/npm/dm/@vite-pwa/vitepress?color=476582&label=">
12
+ </a>
13
+ <a href="https://vite-pwa-org.netlify.app/frameworks/vitepress" target="__blank">
14
+ <img src="https://img.shields.io/static/v1?label=&message=docs%20%26%20guides&color=2e859c" alt="Docs & Guides">
15
+ </a>
16
+ <br>
17
+ <a href="https://github.com/vite-pwa/vitepress" target="__blank">
18
+ <img alt="GitHub stars" src="https://img.shields.io/github/stars/vite-pwa/vitepress?style=social">
19
+ </a>
20
+ </p>
21
+
22
+ <br>
23
+
24
+ <p align="center">
25
+ <a href="https://cdn.jsdelivr.net/gh/antfu/static/sponsors.svg">
26
+ <img src='https://cdn.jsdelivr.net/gh/antfu/static/sponsors.svg'/>
27
+ </a>
28
+ </p>
29
+
30
+ ## ๐Ÿš€ Features
31
+
32
+ - ๐Ÿ“– [**Documentation & guides**](https://vite-pwa-org.netlify.app/)
33
+ - ๐Ÿ‘Œ **Zero-Config**: sensible built-in default configs for common use cases
34
+ - ๐Ÿ”ฉ **Extensible**: expose the full ability to customize the behavior of the plugin
35
+ - ๐Ÿฆพ **Type Strong**: written in [TypeScript](https://www.typescriptlang.org/)
36
+ - ๐Ÿ”Œ **Offline Support**: generate service worker with offline support (via Workbox)
37
+ - โšก **Fully tree shakable**: auto inject Web App Manifest
38
+ - ๐Ÿ’ฌ **Prompt for new content**: built-in support for Vanilla JavaScript, Vue 3, React, Svelte, SolidJS and Preact
39
+ - โš™๏ธ **Stale-while-revalidate**: automatic reload when new content is available
40
+ - โœจ **Static assets handling**: configure static assets for offline support
41
+ - ๐Ÿž **Development Support**: debug your custom service worker logic as you develop your application
42
+ - ๐Ÿ› ๏ธ **Versatile**: integration with meta frameworks: [รฎles](https://github.com/ElMassimo/iles), [SvelteKit](https://github.com/sveltejs/kit), [VitePress](https://github.com/vuejs/vitepress), [Astro](https://github.com/withastro/astro), [Nuxt 3](https://github.com/nuxt/nuxt) and [Remix](https://github.com/remix-run/remix)
43
+ - ๐Ÿ’ฅ **PWA Assets Generator**: generate all the PWA assets from a single command and a single source image
44
+ - ๐Ÿš€ **PWA Assets Integration**: serving, generating and injecting PWA Assets on the fly in your application
45
+
46
+ ## ๐Ÿ“ฆ Install
47
+
48
+ > From v0.3, `@vite-pwa/vitepress` requires **Vite 5** and **VitePress 1.0.0-rc.26 or above**.
49
+
50
+ > Using any version older than v0.3 requires Vite 3.1.0+.
51
+
52
+ ```bash
53
+ npm i @vite-pwa/vitepress -D
54
+
55
+ # yarn
56
+ yarn add @vite-pwa/vitepress -D
57
+
58
+ # pnpm
59
+ pnpm add @vite-pwa/vitepress -D
60
+ ```
61
+
62
+ ## ๐Ÿฆ„ Usage
63
+
64
+ You will need to wrap your VitePress config with `withPwa`:
65
+
66
+ ```ts
67
+ // .vitepress/config.ts
68
+ import { withPwa } from '@vite-pwa/vitepress'
69
+ import { defineConfig } from 'vitepress'
70
+
71
+ export default withPwa(defineConfig({
72
+ /* your VitePress options */
73
+ /* Vite PWA Options */
74
+ pwa: {}
75
+ }))
76
+ ```
77
+
78
+ Read the [๐Ÿ“– documentation](https://vite-pwa-org.netlify.app/frameworks/vitepress) for a complete guide on how to configure and use
79
+ this plugin.
80
+
81
+ ## ๐Ÿ‘€ Full config
82
+
83
+ Check out the type declaration [src/types.ts](./src/types.ts) and the following links for more details.
84
+
85
+ - [Web app manifests](https://developer.mozilla.org/en-US/docs/Web/Manifest)
86
+ - [Workbox](https://developers.google.com/web/tools/workbox)
87
+
88
+ ## ๐Ÿ“„ License
89
+
90
+ [MIT](./LICENSE) License &copy; 2022-PRESENT [Anthony Fu](https://github.com/antfu)
package/index.d.ts CHANGED
@@ -1 +1 @@
1
- export * from './dist'
1
+ export * from './dist'
package/package.json CHANGED
@@ -1,8 +1,7 @@
1
1
  {
2
2
  "name": "@vite-pwa/vitepress",
3
3
  "type": "module",
4
- "version": "1.0.0",
5
- "packageManager": "pnpm@10.7.0",
4
+ "version": "1.0.1",
6
5
  "description": "Zero-config PWA for VitePress",
7
6
  "author": "antfu <anthonyfu117@hotmail.com>",
8
7
  "license": "MIT",
@@ -35,16 +34,9 @@
35
34
  "*.d.ts",
36
35
  "dist"
37
36
  ],
38
- "scripts": {
39
- "build": "unbuild",
40
- "lint": "eslint .",
41
- "lint:fix": "nr lint --fix",
42
- "prepublishOnly": "npm run build",
43
- "release": "bumpp && npm publish"
44
- },
45
37
  "peerDependencies": {
46
38
  "@vite-pwa/assets-generator": "^1.0.0",
47
- "vite-plugin-pwa": "^1.0.0"
39
+ "vite-plugin-pwa": "^1.1.0"
48
40
  },
49
41
  "peerDependenciesMeta": {
50
42
  "@vite-pwa/assets-generator": {
@@ -63,21 +55,13 @@
63
55
  "typescript": "^5.4.5",
64
56
  "unbuild": "^2.0.0",
65
57
  "vite": "^5.2.10",
66
- "vite-plugin-pwa": "^1.0.0",
58
+ "vite-plugin-pwa": "^1.1.0",
67
59
  "vitepress": "^1.1.4"
68
60
  },
69
- "pnpm": {
70
- "peerDependencyRules": {
71
- "ignoreMissing": [
72
- "@algolia/client-search"
73
- ]
74
- },
75
- "ignoredBuiltDependencies": [
76
- "esbuild",
77
- "vue-demi"
78
- ],
79
- "onlyBuiltDependencies": [
80
- "sharp"
81
- ]
61
+ "scripts": {
62
+ "build": "unbuild",
63
+ "lint": "eslint .",
64
+ "lint:fix": "nr lint --fix",
65
+ "release": "bumpp"
82
66
  }
83
- }
67
+ }