feat: robots.txt
This commit is contained in:
parent
a2ea5f6aec
commit
afbffd4606
8 changed files with 32 additions and 8 deletions
|
|
@ -6,6 +6,10 @@ import UsernameForm from "@/components/username-form";
|
|||
export const metadata: Metadata = {
|
||||
title: "Create your Username - TomodachiShare",
|
||||
description: "Pick a unique username to start using TomodachiShare",
|
||||
robots: {
|
||||
index: false,
|
||||
follow: false,
|
||||
},
|
||||
};
|
||||
|
||||
export default async function CreateUsernamePage() {
|
||||
|
|
|
|||
|
|
@ -21,6 +21,10 @@ export async function generateMetadata({ params }: Props): Promise<Metadata> {
|
|||
return {
|
||||
title: `${mii?.name} - TomodachiShare`,
|
||||
description: `Edit the name, tags, and images of '${mii?.name}'`,
|
||||
robots: {
|
||||
index: false,
|
||||
follow: false,
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -15,6 +15,10 @@ const lexend = Lexend({
|
|||
export const metadata: Metadata = {
|
||||
title: "TomodachiShare",
|
||||
description: "Discover and share Mii residents for your Tomodachi Life island!",
|
||||
robots: {
|
||||
index: true,
|
||||
follow: true,
|
||||
},
|
||||
};
|
||||
|
||||
export default function RootLayout({
|
||||
|
|
|
|||
|
|
@ -68,10 +68,6 @@ export async function generateMetadata({ params }: Props): Promise<Metadata> {
|
|||
alternates: {
|
||||
canonical: `/mii/${mii.id}`,
|
||||
},
|
||||
robots: {
|
||||
index: true,
|
||||
follow: true,
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -63,10 +63,6 @@ export async function generateMetadata({ params }: Props): Promise<Metadata> {
|
|||
alternates: {
|
||||
canonical: `/profile/${user.id}`,
|
||||
},
|
||||
robots: {
|
||||
index: true,
|
||||
follow: true,
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -13,6 +13,10 @@ import ProfileSettings from "@/components/profile-settings";
|
|||
export const metadata: Metadata = {
|
||||
title: "Profile Settings - TomodachiShare",
|
||||
description: "Change your account info or delete it",
|
||||
robots: {
|
||||
index: false,
|
||||
follow: false,
|
||||
},
|
||||
};
|
||||
|
||||
export default async function ProfileSettingsPage() {
|
||||
|
|
|
|||
12
src/app/robots.ts
Normal file
12
src/app/robots.ts
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
import type { MetadataRoute } from "next";
|
||||
|
||||
export default function robots(): MetadataRoute.Robots {
|
||||
return {
|
||||
rules: {
|
||||
userAgent: "*",
|
||||
allow: "/",
|
||||
disallow: ["/create-username", "/edit/*", "/profile/settings", "/random", "/submit"],
|
||||
},
|
||||
sitemap: `${process.env.BASE_URL}/sitemap.xml`,
|
||||
};
|
||||
}
|
||||
|
|
@ -6,6 +6,10 @@ import SubmitForm from "@/components/submit-form";
|
|||
export const metadata: Metadata = {
|
||||
title: "Submit a Mii - TomodachiShare",
|
||||
description: "Upload your Tomodachi Life Mii through its QR code and share it with others",
|
||||
robots: {
|
||||
index: false,
|
||||
follow: false,
|
||||
},
|
||||
};
|
||||
|
||||
export default async function SubmitPage() {
|
||||
|
|
|
|||
Loading…
Reference in a new issue