Files
base/ui/vite.config.js
zeekay 7c8b6bd5a4 fix(ui): resolve @hanzo/base/compat for Docker builds
The Vite alias 'base' -> '@hanzo/base/compat' failed in Docker because
the file:../sdk/base-js link can't resolve when only ui/ is copied into
the build context. Since @hanzo/base/compat is just a re-export of the
pocketbase package, alias 'base' directly to 'pocketbase' and add it as
a direct devDependency, removing the file: link.
2026-03-02 01:22:56 -07:00

33 lines
792 B
JavaScript

import { defineConfig } from 'vite';
import { svelte, vitePreprocess } from '@sveltejs/vite-plugin-svelte';
// see https://vitejs.dev/config
export default defineConfig({
server: {
port: 7777,
},
envPrefix: 'HZ',
base: './',
build: {
chunkSizeWarningLimit: 1000,
reportCompressedSize: false,
},
plugins: [
svelte({
preprocess: [vitePreprocess()],
onwarn: (warning, handler) => {
if (warning.code.startsWith('a11y-')) {
return; // silence a11y warnings
}
handler(warning);
},
}),
],
resolve: {
alias: {
'@': __dirname + '/src',
'base': 'pocketbase',
}
},
})