From 737a342c3b01b6f8157531c97cef74db7ee3d5fc Mon Sep 17 00:00:00 2001 From: Dorian Niemiec Date: Sun, 8 Sep 2024 20:39:05 +0200 Subject: [PATCH] feat: add script for robots.txt file generation --- app/robots.ts | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 app/robots.ts diff --git a/app/robots.ts b/app/robots.ts new file mode 100644 index 0000000..ba4e2d2 --- /dev/null +++ b/app/robots.ts @@ -0,0 +1,12 @@ +import type { MetadataRoute } from "next"; + +export default function robots(): MetadataRoute.Robots { + return { + rules: { + userAgent: "*", + allow: "/", + disallow: "/unsubscribe" + }, + sitemap: `${process.env.NEXT_PUBLIC_WEBSITE_URL}/sitemap.xml` + }; +}