feat: add pwa support

pull/581/head
Ryan Wang 2022-05-11 19:22:10 +08:00
parent 400182c714
commit 43407db1b6
3 changed files with 1818 additions and 1 deletions

View File

@ -57,6 +57,7 @@
"unplugin-icons": "^0.14.3",
"vite": "^2.9.8",
"vite-compression-plugin": "^0.0.3",
"vite-plugin-pwa": "^0.12.0",
"vitest": "^0.12.3",
"vue-tsc": "^0.34.11"
}

File diff suppressed because it is too large Load Diff

View File

@ -5,10 +5,23 @@ import vue from "@vitejs/plugin-vue";
import vueJsx from "@vitejs/plugin-vue-jsx";
import icons from "unplugin-icons/vite";
import Compression from "vite-compression-plugin";
import { VitePWA } from "vite-plugin-pwa";
// https://vitejs.dev/config/
export default defineConfig({
plugins: [vue(), vueJsx(), icons(), Compression()],
plugins: [
vue(),
vueJsx(),
icons(),
Compression(),
VitePWA({
manifest: {
name: "Halo",
short_name: "Halo",
description: "Web Client For Halo",
},
}),
],
resolve: {
alias: {
"@": fileURLToPath(new URL("./src", import.meta.url)),