char-slop/chordpad.vibed.software

git clone https://git.t4t.associates/char-slop/chordpad.vibed.software

Charlotte Sominitial commit3c7bc6e

main
685 B22 linesraw
1import deno from "@deno/vite-plugin";
2import { defineConfig } from "vite";
3
4// vite reads neither deno.json's compilerOptions nor (for the dep scanner) its own oxc config
5const jsx = { runtime: "automatic", importSource: "@char/aftercare" } as const;
6
7// TheoryTab pages can't be read cross-origin, so imports fetch them through here
8const proxy = {
9  "/hooktheory": {
10    target: "https://www.hooktheory.com",
11    changeOrigin: true,
12    rewrite: (path: string) => path.replace(/^\/hooktheory/, ""),
13  },
14};
15
16export default defineConfig({
17  server: { proxy },
18  preview: { proxy },
19  plugins: [deno()],
20  oxc: { jsx },
21  optimizeDeps: { rolldownOptions: { transform: { jsx } } },
22});