54 lines
1.5 KiB
TypeScript
Executable File
54 lines
1.5 KiB
TypeScript
Executable File
// // vite.config.ts
|
|
import { defineConfig } from "npm:vite@^7.2.4";
|
|
import { fresh } from "@fresh/plugin-vite";
|
|
import tailwindcss from "@tailwindcss/vite";
|
|
|
|
export default defineConfig({
|
|
publicDir: "static",
|
|
plugins: [fresh(), tailwindcss()],
|
|
|
|
server: {
|
|
port: Number(Deno.env.get("PORT")) || 8080,
|
|
strictPort: true,
|
|
host: Deno.env.get("HOSTNAME_DENO") || "0.0.0.0",
|
|
allowedHosts: ["data1.cyberhybridhub.com", "localhost", "127.0.0.1"],
|
|
},
|
|
preview: {
|
|
port: Number(Deno.env.get("PORT")) || 8080,
|
|
strictPort: true,
|
|
host: Deno.env.get("HOSTNAME_DENO") || "0.0.0.0",
|
|
allowedHosts: ["data1.cyberhybridhub.com", "localhost", "127.0.0.1"],
|
|
},
|
|
});
|
|
|
|
// import { defineConfig, normalizePath } from "vite";
|
|
// import { fresh } from "@fresh/plugin-vite";
|
|
// import tailwindcss from "@tailwindcss/vite";
|
|
// // import { viteStaticCopy } from "@vite-plugin-static-copy";
|
|
// // import path from "node:path";
|
|
|
|
// export default defineConfig({
|
|
// plugins: [
|
|
// fresh(),
|
|
// tailwindcss(),
|
|
// // viteStaticCopy({
|
|
// // targets: [
|
|
// // {
|
|
// // src: normalizePath(path.resolve("assets/kvWorker.ts")),
|
|
// // dest: "./",
|
|
// // },
|
|
// // ],
|
|
// // }),
|
|
// ],
|
|
// server: {
|
|
// port: Number(Deno.env.get("PORT")) || 8080,
|
|
// strictPort: true,
|
|
// host: Deno.env.get("HOSTNAME_DENO") || "0.0.0.0",
|
|
// },
|
|
// preview: {
|
|
// port: Number(Deno.env.get("PORT")) || 8080,
|
|
// strictPort: true,
|
|
// host: Deno.env.get("HOSTNAME_DENO") || "0.0.0.0",
|
|
// },
|
|
// });
|