mirror of
https://github.com/RhenCloud/Cloud-Home.git
synced 2026-03-10 06:32:40 +08:00
feat: 添加 @nuxtjs/robots 模块以支持搜索引擎优化
This commit is contained in:
@@ -5,7 +5,15 @@ import tailwindcss from "@tailwindcss/vite";
|
||||
export default defineNuxtConfig({
|
||||
compatibilityDate: "2025-12-12",
|
||||
srcDir: "app",
|
||||
modules: ["@nuxt/image", "@nuxt/eslint", "@nuxtjs/sitemap", "@nuxt/icon", "@nuxtjs/seo"],
|
||||
|
||||
modules: [
|
||||
"@nuxt/image",
|
||||
"@nuxt/eslint",
|
||||
"@nuxtjs/robots",
|
||||
"@nuxtjs/sitemap",
|
||||
"@nuxt/icon",
|
||||
"@nuxtjs/seo",
|
||||
],
|
||||
|
||||
// 禁用 Vue Router 的非关键警告
|
||||
vue: {
|
||||
@@ -39,6 +47,12 @@ export default defineNuxtConfig({
|
||||
"/friends": { prerender: true },
|
||||
},
|
||||
|
||||
robots: { groups: [{ userAgent: ["GPTBot", "ChatGPT-User"], disallow: ["/"] }] },
|
||||
|
||||
sitemap: {
|
||||
zeroRuntime: true,
|
||||
},
|
||||
|
||||
app: {
|
||||
head: {
|
||||
charset: "utf-8",
|
||||
|
||||
Reference in New Issue
Block a user