initial recommit

This commit is contained in:
2025-04-22 11:30:05 +02:00
parent d37de6d304
commit 9e17369f11
49 changed files with 13964 additions and 3952 deletions

View File

@ -1,6 +1,6 @@
import { defineConfig } from 'astro/config'
import tailwind from "@astrojs/tailwind"
import node from "@astrojs/node"
import svelte from '@astrojs/svelte'
import routing from './hooks/routing'
// const faviconHook = {
@ -14,13 +14,10 @@ import routing from './hooks/routing'
// }
// }
const isProd = !process.env.TAURI_DEBUG
// https://astro.build/config
export default defineConfig({
// Use the NodeJS adapter
adapter: node({
mode: "standalone"
}),
// some settings to the build output
build: {
// the asset path
@ -31,13 +28,13 @@ export default defineConfig({
},
// Compress the HTML output
compressHTML: true,
compressHTML: isProd ? true : false,
// Customizable depending on goal
output: 'server',
output: 'static',
// Add TailwindCSS
integrations: [tailwind(), routing()],
integrations: [svelte(), tailwind(), routing()],
// prefetch links
prefetch: {
@ -50,7 +47,10 @@ export default defineConfig({
// the Output server
server: {
host: true,
port: 3000
port: 3000,
watch: {
ignored: ['**/target/**']
}
},
// Remove the trailing slash by default
@ -58,6 +58,7 @@ export default defineConfig({
// Dev Server
vite: {
envPrefix: ['VITE_', 'TAURI_'],
server: {
watch: {
// Ignore some paths
@ -65,8 +66,15 @@ export default defineConfig({
// support polling and WSL
usePolling: !!(process.env.USE_POLLING ?? process.env.WSL_DISTRO_NAME)
}
},
build: {
target: process.env.TAURI_ENV_PLATFORM == 'windows' ? 'chrome105' : 'safari13',
// don't minify for debug builds
minify: isProd ? 'esbuild' : false,
// produce sourcemaps for debug builds
sourcemap: !isProd,
}
},
})
})