Skip to content
This repository was archived by the owner on Jun 24, 2025. It is now read-only.

Commit 296c95e

Browse files
committed
chore(nx): configure for SvelteKit
1 parent 6416c6b commit 296c95e

2 files changed

Lines changed: 20 additions & 10 deletions

File tree

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -52,3 +52,4 @@ upload
5252
*.tsbuildinfo
5353

5454
/result
55+
.svelte-kit

apps/website/vite.config.ts

Lines changed: 19 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,22 @@ import { paraglideVitePlugin } from '@inlang/paraglide-js';
33
import { sveltekit } from '@sveltejs/kit/vite';
44
import { defineConfig } from 'vite';
55

6-
export default defineConfig({
7-
plugins: [
8-
tailwindcss(),
9-
sveltekit(),
10-
paraglideVitePlugin({
11-
project: './project.inlang',
12-
outdir: './src/lib/paraglide'
13-
})
14-
]
15-
});
6+
export default () => {
7+
// See https://github.com/nrwl/nx/issues/28978.
8+
const cwd = process.cwd();
9+
process.chdir(__dirname); // Temporarily change the working directory
10+
11+
const config = defineConfig({
12+
plugins: [
13+
tailwindcss(),
14+
sveltekit(),
15+
paraglideVitePlugin({
16+
project: './project.inlang',
17+
outdir: './src/lib/paraglide'
18+
})
19+
]
20+
});
21+
22+
process.chdir(cwd); // Restore the original working directory
23+
return config;
24+
};

0 commit comments

Comments
 (0)