28 lines
815 B
TypeScript
28 lines
815 B
TypeScript
import { methaniumUi } from "@methanium/ui/vite";
|
|
import { tanstackRouter } from "@tanstack/router-plugin/vite";
|
|
import tailwindcss from "@tailwindcss/vite";
|
|
import react from "@vitejs/plugin-react";
|
|
import { mtp } from "mtp/vite";
|
|
import path from "node:path";
|
|
import { fileURLToPath } from "node:url";
|
|
import { defineConfig, type Plugin } from "vite";
|
|
|
|
const root = path.dirname(fileURLToPath(import.meta.url));
|
|
|
|
export default defineConfig({
|
|
plugins: [
|
|
tanstackRouter({ target: "react", autoCodeSplitting: true }),
|
|
tailwindcss(),
|
|
react(),
|
|
methaniumUi({ defaultThemeId: "methanium" }),
|
|
mtp({ typeMaps: "./type-maps.yaml" }) as Plugin,
|
|
],
|
|
resolve: {
|
|
alias: {
|
|
"@methanium/template-mtp": path.resolve(
|
|
root,
|
|
"../../packages/mtp/index.ts",
|
|
),
|
|
},
|
|
},
|
|
});
|