Theo's Typesafe Cult

TTC

Theo's Typesafe Cult

Join the community to ask questions about Theo's Typesafe Cult and get answers from other members.

Join

T3 Premium 100/100 full until 2 days! ??

Does anyone know what exactly is included in the premium 100 credits? My credit started up again 2 days ago and I'm at 100/100!! I don't use anything but grok2.5 pro! Can anyone explain this? 🙂 Does coding also eat up premium credits? Is there a description somewhere about how much each model eats?

Uploadthing onUploadComplete not triggering nextjs 15I am using Supabase Auth in Next.js,

I couldn't figure out the solution for more than 6 hours now. I am using Supabase Auth in Next.js, tried to implement uploathing for saving user avatar. The onUploadComplete method is not triggering, although the image is successfully uploaded on the dashboard....
No description

What browser is this? The 'Helium' browser?

I'm searching for it online but can only find an old Helium floating browser from 2015
No description

Uploadthing Duplicate File Detection

How should one handle duplicate file uploads? for example, if I upload test.pdf and then try uploading it again, how do I make sure that the duplicate doesn’t get stored inside uploadthing? (If page is refreshed then the file wouldn’t be considered a duplicate) More worried about the backend part Also, should I rate limit file uploads? if so whats a suggested frequency/interval...

Upload Thing Get All Files

I read the documentation and i have to say i dont quite understand if its possible and how to get all the files.

Environment variables in command line script outside

I'm trying to create a simple command line script (ultimately to load my database, but I've not got that far yet). I'm hitting a 'Invalid environment variables' problem.
env-test.ts: import nextEnv from "@next/env";...

hi! Is there a maximum rpm for uploadthing?

I´m trying to undesrtand if there is a maximum request per minute?

debugging live in REPL (Bun)

Hey all, I'm trying to debug some stuff but would like to evaluate and declare variables after the script has finished executing its code. If I use a debugger, it pauses execution so I can't really interact with the environment like I would be able to in say a browser console. Is there a way to do this?...

REST API design error response

Hi, I have a question about API design. When my service receives an invalid POST body, I currently return only an HTTP 400 with no additional content. My reasoning is that normal users always go through my frontend, which already performs client-side validation, so they should never encounter this error. While reviewing other APIs, I noticed that they often return extra information. What do you recommend?...

Does T3.chat support any querystring arguments like /?q=my-prompt ?

I was watching https://www.youtube.com/watch?v=6koQP6-6mtY and saw Theo was able to type a prompt in a new tab field (in Zen) and it submitted it directly to T3.chat, saving a ton of time. I was hoping I could do the same in Chrome by creating a custom search engine in chrome://settings/searchEngines . I figured it might be something like https://beta.t3.chat/?q=sup-nerds but I tried that and the prompt was not entered into the text box. Is this a supported feature or a feature request? (meta: first time poster here. This question seems on-topic for #t3-chat but it was made very clear I should only ask questions in questions so that's why I'm here but there's no t3-chat tag here, hence the Noob tag. Thanks!)...
Solution:
I found it. https://beta.t3.chat/settings/models and then the 'Search URL' button next to any model

Uploadthing onUploadAborted not working?

I was wondering why I got an error when trying to use onUploadAborted inside my useUploadThing hook it says it doesnt exist tried to fix it but couldnt, my uploadthing is also up to date...
Solution:
i had this same issue. you can read below this message to see what conversation took place: https://discord.com/channels/966627436387266600/1102510616326967306/1351067059844546561 the summary is that this onUploadAborted function isn't exposed in the hook. the docs havn't been updated it seems like. you have 2 solutions: ...
No description

Issue with missing-suspense-with-csr-bailout error while upgrading to Next 15

I'm upgrading my project to Next 15, ran the codemod and fix a few errors. Right now I'm stuck with this missing-suspense-with-csr-bailout error where you don't wrap a component that use useSearchParams in a Suspense tag. Previously we used the missingSuspenseWithCSRBailout: false, flag to go pass it in the build but looks like it's no longer working for v15 Anyways I followed the error messages from the vercel dashboard and add a Suspense wrapper on the first client component in the tree but for some reason it's still have the same error on that route and sometimes even errors on other routes that doesn't have that error in previous builds Am I even on the right track? Do I need to find every useSearchParams implementation on every component and custom hooks? Are we living in a simulation? Help please 😭...
No description

Has someone used excalidraw in their next.js project?

If so could you help with a problem that I have with it?
Solution:
Fixed it

T3 Env bundles ALL (even server) envs in build output (Next.js 15)

When using t3 env package in Next.js it seems that it loads everything (partially) into my main-app-[random-hash].js (build output from webpack) The actual value of the server envs are not bundled but the name of the env is. This poses a security risk because now you can see what packages I use on the server to maybe find an exploit. Is this something I'm doing wrong or is it a bug in the package itself?...
Solution:
No description

Passing Cookies / Authentication For QStash

Summery: Adding cookies / authentication in my qstash schedule as the API route is protected Note: Everything works fine locally when i use postman for api testing. QStash does hit the endpoint correctly in prod / testing locally...
Solution:
the solution was using this header
No description

generation

Sorry. New here (but paying for t3). In chatGPT im able to upload an image to give it context / inspiration. Is this not possible currently in the t3.chat app?...

NPM Error when Upgrading from 7.4.1 to 7.7.2 (NextJS14)

Howdy fellow coders. I went to update an app Ive been finalizing for someone, which worked perfectly fine before today as far as building goes - It had said something about the url callback that is now .ufsUrl had been deprecated - still worked though. today I got this type error: Property 'ufsUrl' does not exist on type 'ClientUploadedFileData<{ uploadedBy: string; }>'. when trying to push what wrre supposed to be just UI/information changes, so I tried to update the @uploadthing package to the current recommended version, and theres a broken dependency stream. ...
No description

Expo + Express on the backend | (maybeServerData ?? data)?.find is not a function

I cant seem to get uploadthing working when using express as a backend with expo. There is a lot of documentation when using expo + expo api routes, but when using express, its lacking and also causes an error that i cant seem to resolve ``` Uncaught Error...
No description

Stop t3-env from asking for env in github actions

Title^^ My ci/cd to vercel is failing as it’s asking me to add my variables to the secrets, but I don’t wanna do that Do I add them to skip validation??...
Solution:
Try the following configuration src/env.ts - config ```ts import { z } from 'zod';...