-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathastro.config.ts
57 lines (55 loc) · 1.2 KB
/
astro.config.ts
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
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
import fs from "node:fs";
import path from "node:path";
import mdx from "@astrojs/mdx";
import nodejs from "@astrojs/node";
import solidJs from "@astrojs/solid-js";
import tailwind from "@astrojs/tailwind";
import { defineConfig } from "astro/config";
import mkcert from "vite-plugin-mkcert";
import wasm from "vite-plugin-wasm";
// https://astro.build/config
export default defineConfig({
integrations: [
mdx(),
solidJs(),
tailwind({
// Disable injecting a basic `base.css` import on every page.
applyBaseStyles: false,
}),
],
// Renders any non-static pages using node
adapter: nodejs({
mode: "standalone",
}),
// Default to static rendering, but allow server rendering per-page
output: "hybrid",
vite: {
build: {
target: "esnext",
},
base: "./",
server: {
fs: {
allow: [
".",
// Allow `bun link @kixelated/moq`
fs.realpathSync(path.resolve("node_modules/@kixelated/moq")),
],
},
},
plugins: [mkcert(), wasm()],
worker: {
format: "es",
plugins: () => [wasm()],
},
resolve: {
alias: {
"@": "/src",
},
},
// Workaround for: https://github.com/vitejs/vite/issues/8427
optimizeDeps: {
exclude: ["@kixelated/moq"],
},
},
});