X-Git-Url: https://git.r.bdr.sh/rbdr/forum/blobdiff_plain/bd8e98d7e24c4dbaee7db6ec7955f7c2f6d396a6..a7500d5b46ad519c9e9a84a342e469bdac0def7a:/svelte.config.cjs?ds=inline diff --git a/svelte.config.cjs b/svelte.config.cjs index cf7a842..cb51cef 100644 --- a/svelte.config.cjs +++ b/svelte.config.cjs @@ -1,11 +1,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: '@sveltejs/adapter-node', + adapter: node(), // hydrate the
element in src/app.html - target: '#forum' + target: '#forum', + + vite: { + ssr: { + noExternal: Object.keys(pkg.dependencies || {}) + }, + resolve: { + alias: { + $: resolve('src') + } + } + } } };