All checks were successful
CI / update (push) Successful in 3m36s
Lightning CSS was deduplicating manually written backdrop-filter + -webkit-backdrop-filter to just the webkit version, breaking blur on Firefox. Remove manual webkit prefixes and let Lightning CSS auto-prefix via browser targets in vite.config.ts.
42 lines
814 B
TypeScript
42 lines
814 B
TypeScript
import { sveltekit } from '@sveltejs/kit/vite';
|
|
import { defineConfig } from 'vite';
|
|
|
|
export default defineConfig({
|
|
css: {
|
|
lightningcss: {
|
|
targets: {
|
|
chrome: (80 << 16),
|
|
firefox: (80 << 16),
|
|
safari: (14 << 16),
|
|
}
|
|
}
|
|
},
|
|
server: {
|
|
allowedHosts: ["bocken.org"]
|
|
},
|
|
plugins: [sveltekit()],
|
|
optimizeDeps: {
|
|
exclude: ['barcode-detector']
|
|
},
|
|
build: {
|
|
rolldownOptions: {
|
|
output: {
|
|
manualChunks: (id) => {
|
|
// Separate large dependencies into their own chunks
|
|
if (id.includes('node_modules')) {
|
|
if (id.includes('chart.js')) {
|
|
return 'chart';
|
|
}
|
|
if (id.includes('@auth/sveltekit')) {
|
|
return 'auth';
|
|
}
|
|
if (id.includes('barcode-detector') || id.includes('zxing-wasm')) {
|
|
return 'barcode';
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
});
|