Skip to content

Commit

Permalink
feat(sitemap): generate robots.txt with sitemap reference
Browse files Browse the repository at this point in the history
  • Loading branch information
mathiazom committed Sep 9, 2024
1 parent 3c1d24f commit ab0b845
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions src/app/robots.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import type { MetadataRoute } from "next";

export default function robots(): MetadataRoute.Robots {
return {
rules: {
userAgent: "*",
},
sitemap: new URL("sitemap.xml", process.env.NEXT_PUBLIC_URL).toString(),
};
}

0 comments on commit ab0b845

Please sign in to comment.