init: project setup

This commit is contained in:
cojocaru-david
2025-04-22 13:53:47 +03:00
commit eb9b1a88be
370 changed files with 33387 additions and 0 deletions

13
src/pages/robots.txt.ts Normal file
View File

@@ -0,0 +1,13 @@
import type { APIRoute } from 'astro'
const getRobotsTxt = (sitemapURL: URL) => `
User-agent: *
Allow: /
Sitemap: ${sitemapURL.href}
`
export const GET: APIRoute = ({ site }) => {
const sitemapURL = new URL('sitemap-index.xml', site)
return new Response(getRobotsTxt(sitemapURL))
}