-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathvite.config.ts
More file actions
65 lines (63 loc) · 1.52 KB
/
Copy pathvite.config.ts
File metadata and controls
65 lines (63 loc) · 1.52 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
import { defineConfig } from "vite";
import react from "@vitejs/plugin-react";
import tailwindcss from "@tailwindcss/vite";
import { VitePWA, VitePWAOptions } from "vite-plugin-pwa";
const pwaOptions: Partial<VitePWAOptions> = {
strategies: "generateSW",
registerType: "autoUpdate",
mode: "production",
base: "/",
includeAssets: ["favicon.svg"],
minify: true,
manifest: {
name: "Malley",
short_name: "Malley",
description: "Malley is a X-like social media platform.",
lang: "en",
dir: "ltr",
id: "/",
orientation: "natural",
launch_handler: {
client_mode: "navigate-existing",
},
protocol_handlers: [],
categories: ["social"],
scope_extensions: [{ origin: "https://malley.afcms.dev" }],
related_applications: [],
prefer_related_applications: false,
theme_color: "#000000",
icons: [
{
src: "favicon.svg",
sizes: "any",
type: "image/svg+xml",
purpose: "any",
},
{
src: "pwa-64x64.png",
sizes: "64x64",
type: "image/png",
},
{
src: "pwa-192x192.png",
sizes: "192x192",
type: "image/png",
},
{
src: "pwa-512x512.png",
sizes: "512x512",
type: "image/png",
},
{
src: "maskable-icon-512x512.png",
sizes: "512x512",
type: "image/png",
purpose: "maskable",
},
],
screenshots: [],
},
};
export default defineConfig({
plugins: [tailwindcss(), react(), VitePWA(pwaOptions)],
});