37 lines
866 B
TypeScript
37 lines
866 B
TypeScript
import { defineConfig } from 'vite';
|
|
import preact from '@preact/preset-vite';
|
|
import { VitePWA } from 'vite-plugin-pwa';
|
|
|
|
// https://vitejs.dev/config/
|
|
export default defineConfig({
|
|
plugins: [
|
|
preact(),
|
|
VitePWA({
|
|
registerType: 'autoUpdate',
|
|
includeAssets: ['favicon.png', 'apple-touch-icon.png'],
|
|
manifest: {
|
|
name: 'SecSan',
|
|
short_name: 'SecSan',
|
|
description: 'Secret santa name drawing',
|
|
theme_color: '#ffffff',
|
|
icons: [
|
|
{
|
|
src: 'favicon.png',
|
|
sizes: '256x256',
|
|
type: 'image/png',
|
|
},
|
|
{
|
|
src: 'favicon-192.png',
|
|
sizes: '192x192',
|
|
type: 'image/png',
|
|
},
|
|
],
|
|
},
|
|
}),
|
|
],
|
|
server: {
|
|
hmr: {
|
|
clientPort: parseInt(process.env.CLIENT_PORT || '5173'),
|
|
},
|
|
},
|
|
});
|