barebones docker | pocketbase | hono | svelte

This commit is contained in:
JCEEE
2026-06-23 21:49:54 +01:00
parent 2253b54077
commit f9d9fa9ace
105 changed files with 27341 additions and 97 deletions
+30 -21
View File
@@ -1,29 +1,38 @@
import tailwindcss from '@tailwindcss/vite';
import { defineConfig } from 'vite';
import adapter from '@sveltejs/adapter-node';
import { sveltekit } from '@sveltejs/kit/vite';
import { defineConfig } from 'vite';
import { PROXY_PORT } from '../config';
import { SERVER_IP, FRONTEND_PORT, PROXY_PORT } from '../config.ts';
export default defineConfig({
plugins: [
tailwindcss(),
sveltekit({
compilerOptions: {
// Force runes mode for the project, except for libraries. Can be removed in svelte 6.
runes: ({ filename }) =>
filename.split(/[/\\]/).includes('node_modules') ? undefined : true,
experimental: { async: true }
export default defineConfig(() => {
return {
plugins: [
tailwindcss(),
sveltekit({
compilerOptions: {
runes: ({ filename }) =>
filename.split(/[/\\]/).includes('node_modules') ? undefined : true,
experimental: { async: true }
},
adapter: adapter(),
experimental: { remoteFunctions: true, handleRenderingErrors: true },
csrf: {
trustedOrigins: ['*']
}
})
],
server: {
fs: {
allow: ['.', './node_modules', '../node_modules']
},
adapter: adapter(),
experimental: { remoteFunctions: true, handleRenderingErrors: true }
})
],
server: {
proxy: {
'/api': {
target: `http://localhost:${PROXY_PORT}`,
changeOrigin: true
allowedHosts: [SERVER_IP],
port: FRONTEND_PORT,
proxy: {
'/api': {
target: `http://${SERVER_IP}:${PROXY_PORT}`,
changeOrigin: true
}
}
}
}
};
});