Skip to content

Commit 27ccde7

Browse files
authored
fix: disable auto generate robots.txt (#913)
1 parent dbe81a9 commit 27ccde7

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

nuxt.config.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -81,6 +81,8 @@ export default defineNuxtConfig({
8181
imports: { autoImport: false },
8282
devtools: { enabled: true },
8383
app: { baseURL: process.env.NODE_ENV === "production" ? "/2025/" : "/" },
84+
// @nuxt/robot don't support generate robots.txt when setting baseURL
85+
robots: { robotsTxt: false },
8486

8587
site: {
8688
// The name and description are set for each language in the following files:

public/robots.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,2 @@
11
User-agent: ClaudeBot
2-
Crawl-delay: 1
2+
Crawl-delay: 1

0 commit comments

Comments
 (0)