aboutsummaryrefslogtreecommitdiffstats
path: root/app/vite.config.ts
blob: c31da3b6d5c0f8698defaab4c9a101e8eecea232 (plain) (blame)
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
import { purgeCss } from 'vite-plugin-tailwind-purgecss';
import { sveltekit } from '@sveltejs/kit/vite';
import { defineConfig } from 'vite';
import { SvelteKitPWA } from '@vite-pwa/sveltekit';

export default defineConfig({
  build: {
    sourcemap: true
  },
  css: {
    devSourcemap: true
  },
  plugins: [
    sveltekit(),
    purgeCss(),
    SvelteKitPWA({
      devOptions: {
        enabled: true,
        type: 'module'
      },
      manifest: {
        name: "RossTheRoss' Personal Tools",
        short_name: 'Dumping Ground',
        display: 'fullscreen',
        display_override: ['window-controls-overlay', 'standalone', 'minimal-ui'],
        icons: [
          {
            src: '/favicon.svg',
            sizes: 'any',
            type: 'image/svg+xml',
            purpose: 'maskable'
          },
          {
            src: '/pwa-512x512.png',
            sizes: '512x512',
            type: 'image/png'
          }
        ],
        id: "/",
        theme_color: '#000000',
      },
      registerType: 'autoUpdate',
      workbox: {
        globPatterns: [ 'client/**/*.{js,css,html,svg}' ],
        cleanupOutdatedCaches: true,
      }
    })
  ]
});