]> git.immae.eu Git - github/bastienwirtz/homer.git/blob - vite.config.js
Fix theming issue & subfolder hosting
[github/bastienwirtz/homer.git] / vite.config.js
1 import { VitePWA } from "vite-plugin-pwa";
2 import { fileURLToPath, URL } from "url";
3
4 import { defineConfig } from "vite";
5 import vue from "@vitejs/plugin-vue";
6
7 // https://vitejs.dev/config/
8 export default defineConfig({
9 base: "",
10 build: {
11 assetsDir: "resources",
12 },
13 plugins: [
14 vue(),
15 VitePWA({
16 registerType: "autoUpdate",
17 useCredentials: true,
18 manifestFilename: "assets/manifest.json",
19 manifest: {
20 name: "Homer dashboard",
21 short_name: "Homer",
22 description: "Home Server Dashboard",
23 theme_color: "#3367D6",
24 icons: [
25 {
26 src: "./icons/pwa-192x192.png",
27 sizes: "192x192",
28 type: "image/png",
29 },
30 {
31 src: "./icons/pwa-512x512.png",
32 sizes: "512x512",
33 type: "image/png",
34 },
35 ],
36 },
37 }),
38 ],
39 resolve: {
40 alias: {
41 "@": fileURLToPath(new URL("./src", import.meta.url)),
42 },
43 },
44 });