This commit is contained in:
2025-05-15 05:20:01 +03:00
parent 623521f3b4
commit 21a05dd202
70 changed files with 4663 additions and 161 deletions

View File

@@ -1,3 +1,26 @@
import { type RouteConfig, index } from "@react-router/dev/routes";
import { type RouteConfig, index, layout, prefix, route } from "@react-router/dev/routes";
export default [index("routes/home.tsx")] satisfies RouteConfig;
export default [
index("routes/index.tsx"),
layout("routes/auth/layout.tsx", [
route("/login", "routes/auth/login.tsx"),
route("/register", "routes/auth/register.tsx"),
]),
...prefix("/app", [
layout("routes/app/layout.tsx", [
index("routes/app/index.tsx"),
...prefix("/@me", [
layout("routes/app/me/layout.tsx", [
index("routes/app/me/index.tsx"),
route("/channels/:channelId", "routes/app/me/channel.tsx"),
])
]),
...prefix("/server/:serverId", [
layout("routes/app/server/layout.tsx", [
index("routes/app/server/index.tsx"),
route("/channels/:channelId", "routes/app/server/channel.tsx"),
])
])
])
]),
] satisfies RouteConfig;