From 9478ddf70bf0d54908f9075b32631323ae3e3181 Mon Sep 17 00:00:00 2001 From: "gpt-engineer-app[bot]" <159125892+gpt-engineer-app[bot]@users.noreply.github.com> Date: Mon, 18 May 2026 22:28:52 +0000 Subject: [PATCH 1/2] Changes Co-authored-by: domfelipe <53182096+domfelipe@users.noreply.github.com> --- public/robots.txt | 10 +++++++ src/routes/sitemap[.]xml.ts | 56 +++++++++++++++++++++++++++++++++++++ 2 files changed, 66 insertions(+) create mode 100644 public/robots.txt create mode 100644 src/routes/sitemap[.]xml.ts diff --git a/public/robots.txt b/public/robots.txt new file mode 100644 index 0000000..c53bbc2 --- /dev/null +++ b/public/robots.txt @@ -0,0 +1,10 @@ +User-agent: * +Allow: / +Disallow: /painel +Disallow: /admin +Disallow: /checkout +Disallow: /bem-vindo +Disallow: /redefinir-senha +Disallow: /recuperar-senha + +Sitemap: https://mika.domco.ai/sitemap.xml diff --git a/src/routes/sitemap[.]xml.ts b/src/routes/sitemap[.]xml.ts new file mode 100644 index 0000000..e7ecdf1 --- /dev/null +++ b/src/routes/sitemap[.]xml.ts @@ -0,0 +1,56 @@ +import { createFileRoute } from "@tanstack/react-router"; +import type {} from "@tanstack/react-start"; + +const BASE_URL = "https://mika.domco.ai"; + +interface SitemapEntry { + path: string; + lastmod?: string; + changefreq?: "always" | "hourly" | "daily" | "weekly" | "monthly" | "yearly" | "never"; + priority?: string; +} + +export const Route = createFileRoute("/sitemap.xml")({ + server: { + handlers: { + GET: async () => { + const today = new Date().toISOString().split("T")[0]; + const entries: SitemapEntry[] = [ + { path: "/", lastmod: today, changefreq: "weekly", priority: "1.0" }, + { path: "/login", lastmod: today, changefreq: "monthly", priority: "0.5" }, + { path: "/signup", lastmod: today, changefreq: "monthly", priority: "0.7" }, + { path: "/termos", lastmod: today, changefreq: "yearly", priority: "0.3" }, + { path: "/privacidade", lastmod: today, changefreq: "yearly", priority: "0.3" }, + { path: "/reembolso", lastmod: today, changefreq: "yearly", priority: "0.3" }, + ]; + + const urls = entries.map((e) => + [ + ` `, + ` ${BASE_URL}${e.path}`, + e.lastmod ? ` ${e.lastmod}` : null, + e.changefreq ? ` ${e.changefreq}` : null, + e.priority ? ` ${e.priority}` : null, + ` `, + ] + .filter(Boolean) + .join("\n"), + ); + + const xml = [ + ``, + ``, + ...urls, + ``, + ].join("\n"); + + return new Response(xml, { + headers: { + "Content-Type": "application/xml", + "Cache-Control": "public, max-age=3600", + }, + }); + }, + }, + }, +}); From 3dc073df741ef9d05cbf144fd4e93f4cdbb65b79 Mon Sep 17 00:00:00 2001 From: "gpt-engineer-app[bot]" <159125892+gpt-engineer-app[bot]@users.noreply.github.com> Date: Mon, 18 May 2026 22:29:04 +0000 Subject: [PATCH 2/2] Changes Co-authored-by: domfelipe <53182096+domfelipe@users.noreply.github.com> --- src/routeTree.gen.ts | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/src/routeTree.gen.ts b/src/routeTree.gen.ts index b960641..0fe84b5 100644 --- a/src/routeTree.gen.ts +++ b/src/routeTree.gen.ts @@ -10,6 +10,7 @@ import { Route as rootRouteImport } from './routes/__root' import { Route as TermosRouteImport } from './routes/termos' +import { Route as SitemapDotxmlRouteImport } from './routes/sitemap[.]xml' import { Route as SignupRouteImport } from './routes/signup' import { Route as ReembolsoRouteImport } from './routes/reembolso' import { Route as RedefinirSenhaRouteImport } from './routes/redefinir-senha' @@ -43,6 +44,11 @@ const TermosRoute = TermosRouteImport.update({ path: '/termos', getParentRoute: () => rootRouteImport, } as any) +const SitemapDotxmlRoute = SitemapDotxmlRouteImport.update({ + id: '/sitemap.xml', + path: '/sitemap.xml', + getParentRoute: () => rootRouteImport, +} as any) const SignupRoute = SignupRouteImport.update({ id: '/signup', path: '/signup', @@ -190,6 +196,7 @@ export interface FileRoutesByFullPath { '/redefinir-senha': typeof RedefinirSenhaRoute '/reembolso': typeof ReembolsoRoute '/signup': typeof SignupRoute + '/sitemap.xml': typeof SitemapDotxmlRoute '/termos': typeof TermosRoute '/checkout/sucesso': typeof CheckoutSucessoRoute '/painel/agente': typeof PainelAgenteRoute @@ -218,6 +225,7 @@ export interface FileRoutesByTo { '/redefinir-senha': typeof RedefinirSenhaRoute '/reembolso': typeof ReembolsoRoute '/signup': typeof SignupRoute + '/sitemap.xml': typeof SitemapDotxmlRoute '/termos': typeof TermosRoute '/checkout/sucesso': typeof CheckoutSucessoRoute '/painel/agente': typeof PainelAgenteRoute @@ -248,6 +256,7 @@ export interface FileRoutesById { '/redefinir-senha': typeof RedefinirSenhaRoute '/reembolso': typeof ReembolsoRoute '/signup': typeof SignupRoute + '/sitemap.xml': typeof SitemapDotxmlRoute '/termos': typeof TermosRoute '/checkout/sucesso': typeof CheckoutSucessoRoute '/painel/agente': typeof PainelAgenteRoute @@ -280,6 +289,7 @@ export interface FileRouteTypes { | '/redefinir-senha' | '/reembolso' | '/signup' + | '/sitemap.xml' | '/termos' | '/checkout/sucesso' | '/painel/agente' @@ -308,6 +318,7 @@ export interface FileRouteTypes { | '/redefinir-senha' | '/reembolso' | '/signup' + | '/sitemap.xml' | '/termos' | '/checkout/sucesso' | '/painel/agente' @@ -337,6 +348,7 @@ export interface FileRouteTypes { | '/redefinir-senha' | '/reembolso' | '/signup' + | '/sitemap.xml' | '/termos' | '/checkout/sucesso' | '/painel/agente' @@ -368,6 +380,7 @@ export interface RootRouteChildren { RedefinirSenhaRoute: typeof RedefinirSenhaRoute ReembolsoRoute: typeof ReembolsoRoute SignupRoute: typeof SignupRoute + SitemapDotxmlRoute: typeof SitemapDotxmlRoute TermosRoute: typeof TermosRoute CheckoutSucessoRoute: typeof CheckoutSucessoRoute } @@ -381,6 +394,13 @@ declare module '@tanstack/react-router' { preLoaderRoute: typeof TermosRouteImport parentRoute: typeof rootRouteImport } + '/sitemap.xml': { + id: '/sitemap.xml' + path: '/sitemap.xml' + fullPath: '/sitemap.xml' + preLoaderRoute: typeof SitemapDotxmlRouteImport + parentRoute: typeof rootRouteImport + } '/signup': { id: '/signup' path: '/signup' @@ -643,6 +663,7 @@ const rootRouteChildren: RootRouteChildren = { RedefinirSenhaRoute: RedefinirSenhaRoute, ReembolsoRoute: ReembolsoRoute, SignupRoute: SignupRoute, + SitemapDotxmlRoute: SitemapDotxmlRoute, TermosRoute: TermosRoute, CheckoutSucessoRoute: CheckoutSucessoRoute, }