Skip to content

Commit 6ca7663

Browse files
committed
refactor: update robots.ts to use array for disallowed paths and format sitemap
1 parent e4d3670 commit 6ca7663

2 files changed

Lines changed: 6 additions & 22 deletions

File tree

public/robots.txt

Lines changed: 0 additions & 21 deletions
This file was deleted.

src/app/robots.ts

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,14 @@ export default function robots(): MetadataRoute.Robots {
44
return {
55
rules: {
66
userAgent: "*",
7+
crawlDelay: 10,
78
allow: "/",
8-
disallow: "/dashboard",
9+
disallow: ["/dashboard", "/backdoor"],
910
},
1011
host: "https://www.techdiary.dev",
12+
sitemap: [
13+
"https://www.techdiary.dev/sitemaps/articles/sitemap.xml",
14+
"https://www.techdiary.dev/sitemaps/profiles/sitemap.xml",
15+
],
1116
};
1217
}

0 commit comments

Comments
 (0)