aboutsummaryrefslogtreecommitdiff
path: root/svelte.config.cjs
blob: cb51cef5c0186f5d42e2a5f51d3c3a70e1c14230 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
const { resolve } = require('path');
const node = require('@sveltejs/adapter-node');
const pkg = require('./package.json');

/** @type {import('@sveltejs/kit').Config} */
module.exports = {
	kit: {
		// By default, `npm run build` will create a standard Node app.
		// You can create optimized builds for different platforms by
		// specifying a different adapter
		adapter: node(),

		// hydrate the <div id="forum"> element in src/app.html
		target: '#forum',

		vite: {
			ssr: {
				noExternal: Object.keys(pkg.dependencies || {})
			},
			resolve: {
				alias: {
					$: resolve('src')
				}
			}
		}
	}
};