mirror of
https://github.com/moku-project/Moku.git
synced 2026-06-13 01:09:56 -05:00
Chore: Restructure Repository for SvelteKit
This commit is contained in:
@@ -0,0 +1,23 @@
|
||||
import adapterStatic from '@sveltejs/adapter-static';
|
||||
import adapterNode from '@sveltejs/adapter-node';
|
||||
|
||||
const target = process.env.MOKU_TARGET ?? 'static';
|
||||
|
||||
const adapter = target === 'node'
|
||||
? adapterNode()
|
||||
: adapterStatic({ fallback: 'index.html' });
|
||||
|
||||
/** @type {import('@sveltejs/kit').Config} */
|
||||
const config = {
|
||||
compilerOptions: {
|
||||
runes: ({ filename }) => (filename.split(/[/\\]/).includes('node_modules') ? undefined : true),
|
||||
},
|
||||
kit: {
|
||||
adapter,
|
||||
files: {
|
||||
assets: 'static',
|
||||
},
|
||||
},
|
||||
};
|
||||
|
||||
export default config;
|
||||
Reference in New Issue
Block a user