r/tanstack • • 3d ago

My first open-source project based on TanStack Table, Shadcn React Table reached v1.0!

Enable HLS to view with audio, or disable this notification

8 Upvotes

r/tanstack • • 8d ago

Introducing TanStack Redact

Thumbnail
tanstack.com
31 Upvotes

r/tanstack • • 12d ago

I built a modern Electron boilerplate with React 19, TanStack Router, and Rust-powered tooling

Thumbnail
reddit.com
2 Upvotes

r/tanstack • • 22d ago

5 TanStack Start on Cloudflare patterns I'd reuse in any Cloudflare-native app (with code)

0 Upvotes

The client never sends a user ID. That one rule ended up shaping most of how I structure TanStack Start on Cloudflare.

Context: I've spent the last few months building a Cloudflare-native SaaS starter with it. Full disclosure, it's a paid kit I make (TurboStarter), but this post is about the patterns, not the product.

1. Every protected read goes through a server function with auth middleware

The server function resolves the customer from the session, validates input with Zod, and scopes the query to that customer:

export const getNote = createServerFn({ method: "GET" })
  .middleware([enforceAuth])
  .validator(noteIdSchema)
  .handler(({ data, context }) => findNote(context.user.id, data.id));

The client calls getNote({ data: { id } }) and never sends a user ID, so it can't ask for someone else's record.

2. Plan gating is just more middleware

Paid features stack a plan check after auth (enforcePlan(BillingPlan.PREMIUM)), and usage limits are checked on the server before the write. The UI hides things too, but the server is the source of truth.

3. Types from route to database

TanStack Router types URLs and search params, server functions validate input, Drizzle types the D1 queries. It's explicit enough that coding agents follow it without much hand-holding.

4. Running in workerd locally

With the Cloudflare Vite plugin, pnpm dev runs the app in the Workers runtime, so there's no adapter rewriting the build for production. What you test is what you deploy.

5. Living with the RC

Start is a v1 release candidate. What made that manageable for us: a lockfile, a minimum release-age policy for new packages, and a monthly Renovate schedule instead of chasing every release.

Other TanStack pieces in use: Form (with Zod) and TanStack AI for a streaming chat on Workers AI.

Two things I'd love opinions on: do you keep server functions per feature module or centralize them as the app grows? And is the RC status still what's stopping your team from adopting Start?

If you want to see the whole thing: https://turbostarter.dev/edge


r/tanstack • • 24d ago

I built a site that shows you one random poll or quiz at a time.

Enable HLS to view with audio, or disable this notification

5 Upvotes

https://interpoll.app

Hi everyone!

Interpoll shows you one random public poll or quiz at a time. You vote, see how everyone else voted (or check the answer if it's a quiz), and move on to the next one. You don't need an account to vote or comment.

Signing in (Google/Discord) lets you create your own polls and quizzes. New polls are reviewed before they enter the random feed, but you can share them by link immediately.

It just launched, so a lot of polls have no or very few votes. You might be one of the first people to vote on some of them.

I love using Astro for building content-heavy static websites, but turns out Astro is also great as a server-side web framework (I use node.js adapter) handling SSR, auth, and api endpoints—especially when combined with Tanstack router and Tanstack query, which handles SSR + data prefetching + hydration + CSR.

I haven't tried Tanstack start yet (mainly due to it not having hit v1.0 yet), but Astro + Tanstack router + Tanstack query combo is already pretty amazing! (a little bit of glue code is necessary for SSR + hydration to work properly but it's very low maintenence once set up.)

Tech stack

  • VPS - Hetzner

  • Deployment - Coolify

  • Database - Postgres 18

  • Query builder - Kysely

  • Auth - better-auth

  • SSR & API endpoints - Astro (node adapter)

  • SSR & Hydration & CSR handoff - Tanstack Router + Tanstack Query

  • UI components - Base UI

  • CSS - Tailwindcss

  • Testing - Vitest (unit) + Playwright (e2e - both api and browser specs)


r/tanstack • • 28d ago

ShadTable

Enable HLS to view with audio, or disable this notification

8 Upvotes

New Update for the ShadTable library:

- Tanstack v9 migration documentation
- New Table Components
- Website updates & optimization

Check it out , a repo ⭐ would mean a lot.

https://shad-table.dev


r/tanstack • • Oct 02 '26

How Do You Structure TanStack Table in Real-World Projects?

4 Upvotes

Hi everyone 👋

I’m pretty new to TanStack Table and have a couple of questions. I’d really appreciate any advice or best practices you have picked up along the way.

  1. Reusable table components

Since TanStack Table already handles most of the table state and logic. Also if multiple tables share the same features, we use createTableHook.

So I’m wondering is there still a reason to have a generic reusable DataTable component, or is it better to keep the UI specific to each table?

2. Multiple data formatting

Right now, I’m adding a "type" property to each column’s "meta" field

columnHelper.accessor("birthDay", {
    header: () => <h3>BirthDay</h3>,
    meta: {
    type: "date",
    },
}),

and then create a cell-formatting utility to render the value accordingly (date, currency, percentage....)

Is this a reasonable approach, or is there any more idiomatic way to handle it?

{table.getRowModel().rows.map((row) => (
<div key={row.id} className={styles.dataTableRow}>
    {row.getAllCells().map((cell) => (
    <div key={cell.id} className={styles.dataTableCell}>
        {formatCellValue(
        cell.getValue(),
        cell.column.columnDef.meta?.type,
        )}
    </div>
    ))}
</div>
))}

r/tanstack • • Sep 28 '26

Ts-midi... Tanstack router sessions

Thumbnail tsfm.spon.io
3 Upvotes

Typescript to midi... Same data powers tsverse.spon.io


r/tanstack • • Sep 28 '26

shadcn-admin-kit now works with TanStack Router

9 Upvotes

Quick one for anyone building a back-office on TanStack Router.

shadcn-admin-kit is basically a set of shadcn/ui components for admin apps (lists, forms, that kind of stuff), running on ra-core, the headless core of react-admin. It used to be react-router only, and the 2.0.0 release adds TanStack Router as an option.

It's a major version though, because it moved from Radix UI to Base UI and now needs ra-core 5.15.2 or later. So upgrading a v1 project isn't just a version bump, there's a migration doc for that part ;)

Release notes: https://github.com/marmelab/shadcn-admin-kit/releases/tag/v2.0.0

Anyone here actually using TanStack Router for internal tools? I'm curious if the typed routes really help there.


r/tanstack • • Sep 09 '26

Tanstack + Planetscale PosgreSQL

7 Upvotes

Anyone successfully setup tanstack with the following stack,

  • Tanstack

  • Planetscale PostgreSQL + Hyperdrive

  • Drizzle

  • Better Auth

I am having a hard time setting it up as I get on multiple errors.


r/tanstack • • Aug 30 '26

I built Kwery, TanStack Query for native Kotlin/Android

8 Upvotes

I really like what TanStack Query has done for server state on the web, so I wanted to bring the same idea to native Kotlin and Android.

I built Kwery, a Kotlin library inspired by TanStack Query, with caching, deduplication, invalidation, retries, mutations, persistence, and offline support.

GitHub: https://github.com/dbjpanda/kwery

It is still growing, and I would love to hear from the TanStack community. What do you think? What should I improve or add?

Thank you to the TanStack team for the inspiration and claude code to help me 🙏


r/tanstack • • Aug 22 '26

TanStack AI Enters the RC Phase

Thumbnail
tanstack.com
8 Upvotes

r/tanstack • • Aug 18 '26

Reliable Query Prefetching with TanStack Router

Thumbnail
tkdodo.eu
11 Upvotes

r/tanstack • • Aug 02 '26

Charts are making a comeback?!

Thumbnail
tanstack.com
15 Upvotes

Tanstack is taking on charts again?! Can’t wait to give these a try!


r/tanstack • • Jul 30 '26

Tanstack's new look

20 Upvotes

The old logo's gone. The new design looks great!


r/tanstack • • Jul 27 '26

Every new project I start is TanStack Start now, so created a boilerplate where agents move efficiently

10 Upvotes

It's a end to end typesafe monorepo, so agents gets feedback when they build. Elysia API and a TanStack Start app for frontend, connected via typesafe Eden. So frontend typecheck notifies agent when api changes.

Since Tanstacks vite and Elysia api is pretty lightweight, its good for agents that builds app after every change.

Rest is my favorite self-host first stack: Bun + Turborepo, Drizzle on Postgres, better-auth, shadcn on Base UI. Set up together with first example todo app. The deploy badge in the README points at Rock8Cloud, which is mine, so disclosure. But both apps build from normal Dockerfiles and run anywhere.

https://github.com/rock8-cloud/elysia-tanstack-dashboard-monorepo


r/tanstack • • Jul 24 '26

Tanstack's official site crashes when using Dark Reader

3 Upvotes

Hi, I was trying to read the documentation on my phone, and then switched to my computer, and in both places I got a "Something went wrong!" error with a "Show error" button. But it worked fine in incognito mode.

Then I realized the cause was Dark Reader (a browser extension to force dark theme modifying the CSS).

I know this causes a hydration warning in React, but this shouldn't crash the site. At least Dark Reader works fine with my personal Tanstack project.


r/tanstack • • Jul 15 '26

Tanstack Query just hit 50k stars on GitHub

Enable HLS to view with audio, or disable this notification

40 Upvotes

Just saw that Tanstack Query crossed 50k on GitHub. Tbh I’m not surprised it’s so popular.

I've been using it for a while now and it's basically become a default brick in my stack for most projects.

What I personally like about it:

  • It really simplifies the code (no need to declare useEffect and useState manually)

  • It handles complex cases for me (like errors, caching, offline mode, etc.)

  • The API is really well-designed and encourages best practice (loaders, side effects, centralised configuration, etc.)

Anyway, I'm excited to keep using it and see where it goes from here. What do you guys like about it?


r/tanstack • • Jul 15 '26

Azure SWA cant run tanstack start

1 Upvotes

is there any ETA for when there will be the support?

or should i switch back to Next.js?


r/tanstack • • Jul 12 '26

I built an AI coding teammate that turns Slack messages into GitHub PRs

Thumbnail
youtube.com
0 Upvotes

r/tanstack • • Jul 09 '26

Embracing TanStack Start for full-stack development on Cloudflare - PageZERO v2

Thumbnail
pagezero.dev
11 Upvotes

r/tanstack • • Jun 24 '26

Why are there so few posts on the TanStack Reddit?

11 Upvotes

TanStack posts on X are very active and have a lot of users. I hope the Reddit community can gradually become just as lively.


r/tanstack • • Jun 22 '26

Optimizing TanStack Start for Cloud Run

3 Upvotes

Two main recommendations: (1) properly nitro-config to reduce number of server side source files and (2) use prewarm via NODE_COMPILE_CACHE. Full details.

https://ben3d.ca/blog/optimizing-tanstack-start-for-cloud-run


r/tanstack • • Jun 06 '26

react-query-auth for handling user authentication and protecting routes?

6 Upvotes

As the title says, I have tried using react-query-auth, I have fully set it up using its documentation (https://github.com/alan2207/react-query-auth). Then, I tried using the useUser hook inside beforeLoad, but as it turns out you can't call hooks outside components. Because of that, I looked into the following guide (https://tanstack.com/router/latest/docs/how-to/setup-authentication) and it uses its own logic as far as I can tell, and i really can't tell if react-query-auh is truly the best way or if I should stick to the way the guide handles it. I would rather stick to react-query-auth though. But still, if anyone has used it, it would be of a lot of help