2023-04-08 14:16:23 +02:00
|
|
|
import path from "path";
|
|
|
|
import { fileURLToPath } from "url";
|
|
|
|
import { defineConfig } from "astro/config";
|
|
|
|
import sitemap from "@astrojs/sitemap";
|
|
|
|
import robotsTxt from "astro-robots-txt";
|
|
|
|
import compress from "astro-compress";
|
|
|
|
import tailwind from "@astrojs/tailwind";
|
|
|
|
import { CONFIG } from "./src/config";
|
2023-04-09 22:00:25 +02:00
|
|
|
import image from "@astrojs/image";
|
2023-04-08 14:16:23 +02:00
|
|
|
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
|
|
|
2023-04-09 22:00:25 +02:00
|
|
|
// https://astro.build/config
|
2023-04-08 14:16:23 +02:00
|
|
|
export default defineConfig({
|
2023-04-09 22:00:25 +02:00
|
|
|
site: CONFIG.origin,
|
|
|
|
base: "/",
|
|
|
|
trailingSlash: "always",
|
|
|
|
output: "static",
|
|
|
|
integrations: [sitemap(), robotsTxt({
|
|
|
|
policy: [{
|
|
|
|
userAgent: "*"
|
|
|
|
}],
|
|
|
|
sitemap: true
|
|
|
|
}), compress({
|
|
|
|
css: true,
|
|
|
|
html: true,
|
|
|
|
img: true,
|
|
|
|
js: true,
|
|
|
|
svg: true
|
|
|
|
}), tailwind(), image()],
|
|
|
|
vite: {
|
|
|
|
resolve: {
|
|
|
|
alias: {
|
|
|
|
"~": path.resolve(__dirname, "./src")
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
});
|