@devries-cameron20 / t3code Mirror · read-only
Fork 0

The best way to control Claude Code, Codex and more from any computer or phone

Mirrored from https://github.com/Camo67/t3code.git

Synced Nov 21, 07:15 UTC

main
ts 24 lines 489 Bytes
Raw
1 // `playground/main-resolution/vite.config.virtual-module-main.ts`.
2 export default {
3 plugins: [
4 {
5 name: "virtual-module-plugin",
6 resolveId(source: string) {
7 if (source === "virtual:entry") {
8 return `\0${source}`;
9 }
10 },
11 load(id: string) {
12 if (id === "\0virtual:entry") {
13 return `
14 export default {
15 fetch() {
16 return new Response("Virtual module as Worker entry file");
17 }
18 }
19 `;
20 }
21 },
22 },
23 ],
24 };