Next.js Discord

Discord Forum

How to Open nested routes

Unanswered
Giant panda posted this in #help-forum
Open in Discord
Giant pandaOP
export const appRouter = t.router({
    show: t.procedure.query(async () => {
        const cities: Cities[] = await db.select().from(city);
        return cities;
    }),
   
    auth: authRouter,
})


export const authRouter = t.router({
    log: t.procedure.query(async () => {
        const cities: Cities[] = await db.select().from(city);
        return cities;
    })

})


when i visit localhost:5000/show , it works but when i visit localhost:5000/auth/log , it does not work anyone who can help me ?

0 Replies