Theo's Typesafe CultTTC
Theo's Typesafe Cult4y ago
15 replies
Tony

AuthSession in T3 boiler plate not working when fetching data in SSG with tRPC

So when fetching data in getStaticProps, the docs instruct to use the SSG headers https://trpc.io/docs/ssg. Now doing this causes the file in server/common/get-server-auth-session to throw errors because the context will be undefined. What's the way to go around this
Screenshot_from_2022-12-28_15-41-19.png
Was this page helpful?