mirror of
https://github.com/ggml-org/llama.cpp.git
synced 2026-08-27 15:41:19 +02:00
f2efd64141
* refactor: Move `styles/` to `src/lib` and remove legacy alias * chore: Add newline
35 lines
858 B
JavaScript
35 lines
858 B
JavaScript
import adapter from '@sveltejs/adapter-static';
|
|
import { vitePreprocess } from '@sveltejs/vite-plugin-svelte';
|
|
import { mdsvex } from 'mdsvex';
|
|
|
|
// CMake sets LLAMA_UI_OUT_DIR to the staging dir under the build tree; manual
|
|
// `npm run build` runs without the env var default to ./dist.
|
|
const outDir = process.env.LLAMA_UI_OUT_DIR ?? './dist';
|
|
/** @type {import('@sveltejs/kit').Config} */
|
|
const config = {
|
|
extensions: ['.svelte', '.svx'],
|
|
|
|
kit: {
|
|
adapter: adapter({
|
|
assets: outDir,
|
|
fallback: 'index.html',
|
|
pages: outDir,
|
|
precompress: false,
|
|
strict: true
|
|
}),
|
|
output: {
|
|
bundleStrategy: 'single'
|
|
},
|
|
paths: {
|
|
relative: true
|
|
},
|
|
router: { type: 'hash' }
|
|
},
|
|
|
|
// Consult https://svelte.dev/docs/kit/integrations
|
|
// for more information about preprocessors
|
|
preprocess: [vitePreprocess(), mdsvex()]
|
|
};
|
|
|
|
export default config;
|