TanStack

T

TanStack

TanStack is a community of passionate software engineers striving for high-quality, open-source software for web devs

Join

react-query-questions

solid-query-questions

table-questions

virtual-questions

router-questions

react-charts-questions

ranger-questions

vue-query-questions

svelte-query-questions

bling-questions

form-questions

angular-query-questions

start-questions

db-questions

start-showcase

router-showcase

📣-announcements

optimistic-gold
optimistic-gold10/26/2024

TanStack Start meets Astro Actions?

So I've been playing around with TanStack Start and really loving it. I've also been looking at Astro Actions and it seems like a pattern like that could work with Start? Like some combination of Server Functions meets tRPC? I'm sure there is plenty to consider, but just wondering if this is possible or something thats on folks' radar. Would be curious to learn about if there's any progress on this or limitations to making it work. Or like, if this would be a tRPC feature....
ambitious-aqua
ambitious-aqua10/26/2024

Redirect to external URL from server function

Hey, how do I redirect to external URL from server function? I want to invoke supabase oauth login
robust-apricot
robust-apricot10/25/2024

Vitest with start

Any examples/suggestions on getting vitest setup with start? Main focus is node tests (for utils/libs) and component tests....
optimistic-gold
optimistic-gold10/24/2024

Public and private environment variables

Context: .env AZURE_STORAGE_CONNECTION_STRING="" config...
exotic-emerald
exotic-emerald10/24/2024

Start - When to use Api routes and server functions

I'm learning tankstack start and i'm not sure about why and when to use API routes, isn't server functions better, since it provides typescript end-to-end support and only executes on the server? Why shouldn't i only use server functions?
national-gold
national-gold10/22/2024

Any equivalent to “use client” for SSR

Just curious if there’s any convenient way to handle components that call for the window etc, without manually adding safety checks. Use case: shadcn components and easy copy paste into a Tanstack Start project that’s using SSR Nextjs has the “use client”, so something convenient like that....
fascinating-indigo
fascinating-indigo10/21/2024

Risk Involved in Adopting Now

I know Tanstack Start is in Alpha and not ready for adoption but I am starting at a new company greenfielding all new products. I have been using NextJS for years so that is my natual instinct but I feel Tanstack Start is perfect for the dashboard apps we need to build. Should we adopt Tanstack Start now and hope for the best? Maybe just use Vite React and Tanstack Query? Or should we just use NextJS since its the current React standard? I feel torn and would really love some honest opinions and feedback. Cant wait for Tanstack Start to be fully released....
evident-indigo
evident-indigo10/21/2024

CSS modules support

I have noticed manual linking of css files to ensure styles load before content. import stylesUrl from "./styles.css?url" links: () => [{ rel: 'stylesheet', href: stylesUrl }]...
correct-apricot
correct-apricot10/21/2024

Server only files?

Remix and others have the concept of 'server' only files usually with by doing .server or similar. How am I supposed to denote that something is server only? I am worried about leaking stuff unintentionally.
harsh-harlequin
harsh-harlequin10/20/2024

_build / wss via host: true

Hey, i'm in the "middle" of migrating over to TS Start. My old vite.config.js has this: ```js import { defineConfig } from 'vite'...
No description
sensitive-blue
sensitive-blue10/19/2024

Methods other then GET and POST in createServerFn

Does tanstack start plan to support HTTP request methods other then GET and POST for createServerFn in the future? Or is there a reason it only supports these two?
sensitive-blue
sensitive-blue10/19/2024

Search params in api routes

Is there a way to validate search (query params) in api routes like it is in regular routes with validateSearch?
ambitious-aqua
ambitious-aqua10/17/2024

Adding scripts inside the Head component

From what I can tell, it doesn't seem possible at the moment to add scripts as children of the Head component. I submitted the following issue a little while back when I tried to use Mantine with Start. I've also tried using the scripts option on the route, but that adds the script to the end of the root div. I'm wondering if there might be a workaround someone has found for this or if it's planned to support adding scripts to the head of a Start app. https://github.com/TanStack/router/issues/1917...
ratty-blush
ratty-blush10/17/2024

Public environment variables doesn't seem to work with vercel

As I thought. Here's a context:
export const TRPC_BASE_URL = import.meta.env.VITE_API_BASE_URL + '/trpc';
export const TRPC_BASE_URL = import.meta.env.VITE_API_BASE_URL + '/trpc';
```ts...
No description
absent-sapphire
absent-sapphire10/17/2024

`app.config.timestamp_NNN.js` files created when running `pnpm dev`

Here is the reproduction steps: - clone https://github.com/TanStack/router - cd router/examples/react/start-trellaux - pnpm i - pnpm dev...
genetic-orange
genetic-orange10/16/2024

(getUserConfig.plugins || []) is not iterable with v1.69.3

Just upgraded... My dependencies: ```...
exotic-emerald
exotic-emerald10/16/2024

Returning errors with status codes in server fn

If my server function return a status code of 400 or other indicating error the mutation automatically rejects and goes to the onError callback The actual error object returned is accessible on error.message but it has been stringified so I have to parse it to get the actual object I returned back but I lose every bit of typesafety and this seems like something could go wrong if I maybe return a string or something some other time...
exotic-emerald
exotic-emerald10/15/2024

setStatus or setResponseStatus doesn't work in server functions

I'm trying to set status code in server fn but it just ignores it and returns 200
sensitive-blue
sensitive-blue10/12/2024

Sending a file via a server function possible?

I am making an application using Start, and one of the requirements is uploading files. Is it possible to send a file through a server function? I know things like Date's cannot be, but this seems like an important use-case in Start
ambitious-aqua
ambitious-aqua10/11/2024

url rewrites support

Does TanStack Start support URL rewrites similar to how it's done in Next.js middleware? My use case is for a multi-tenant application which supports Sub domain routing