Help - session type in _app.tsx is missing

I recently opened my _app.tsx and noticed that there was an error with the session object being destructured in the app. I'm not too sure what went wrong here, but I did remove and reinstall my node_modules for good measure, and no luck. Repo link - https://github.com/SeanCassiere/next-discord-clone/blob/master/src/pages/_app.tsx#L17 Would appreciate it if anyone could let me know what I messed up.
GitHub
next-discord-clone/_app.tsx at master · SeanCassiere/next-discord-c...
(WIP) - A Discord clone with the T3 Stack. Contribute to SeanCassiere/next-discord-clone development by creating an account on GitHub.
20 Replies
Sean Cassiere
Sean CassiereOP•3y ago
More context, pageProps is {} 😲
Piotrek
Piotrek•3y ago
It's new in Next 12.3 I think (they changed pageProps from any to {}) You'll have to add typing yourself
Sean Cassiere
Sean CassiereOP•3y ago
Thanks @Piotrek
Sean Cassiere
Sean CassiereOP•3y ago
time for any-casting
Sean Cassiere
Sean CassiereOP•3y ago
@nexxel @julius Should an issue be created in the ct3a repo for this? Assuming, ct3a moves on to next-12.3 this would then affect new projects inited by others yes? Basically, ct3a providing its own types or any-casting, or something....
Unknown User
Unknown User•3y ago
Message Not Public
Sign In & Join Server To View
nexxel
nexxel•3y ago
GitHub
bug: session type issue on NextJs 12.3.0 · Issue #412 · t3-oss/cr...
Provide environment information System: OS: Windows 10 10.0.22000 CPU: (16) x64 12th Gen Intel(R) Core(TM) i5-1240P Memory: 1.77 GB / 15.69 GB Binaries: Node: 16.15.1 - C:\Program Files\nodejs\node...
nexxel
nexxel•3y ago
it will be fixed in the next nextjs release
Sean Cassiere
Sean CassiereOP•3y ago
Cool stuff, thanks a bunch.
nexxel
nexxel•3y ago
GitHub
feat(ts): expose AppType by balazsorban44 · Pull Request #40391 ·...
An alternative solution to #40371 Ref: #38867, t3-oss/create-t3-app#412, t3-oss/create-t3-app#414 Bug Related issues linked using fixes #number Integration tests added Errors have helpful link ...
Unknown User
Unknown User•3y ago
Message Not Public
Sign In & Join Server To View
Sean Cassiere
Sean CassiereOP•3y ago
Believe so, I myself just ugraded to 12.3 like a day back and noticed this today
julius
julius•3y ago
Sean Cassiere
Sean CassiereOP•3y ago
Looks like 12.3.1 is out!
Unknown User
Unknown User•3y ago
Message Not Public
Sign In & Join Server To View
Sean Cassiere
Sean CassiereOP•3y ago
There are some breaking changes from the provided ct3a template that I've found, but I'll leave this up to the Giga-brain peeps in the t3 community. #9 The import for AppType now must come from next/app. Not mandatory, but it was recommended of sorts (https://github.com/vercel/next.js/issues/40371#issuecomment-1241805459). #19 The import will need to be typed with the Session from next-auth.
GitHub
bug(typedef): AppType typedef changed in 12.3 · Issue #40371 · verc...
Verify canary release I verified that the issue exists in the latest Next.js canary release Provide environment information Operating System: Platform: darwin Arch: arm64 Version: Darwin Kernel Ver...
nexxel
nexxel•3y ago
im making a pr
nexxel
nexxel•3y ago
GitHub
fix(template): bump next to 12.3.1 and fix AppType by nexxeln · Pul...
✅ Checklist I have followed every step in the contributing guide (updated 2022-08-15). The PR title follows the convention we established conventional-commit I performed a functional test on my...
nexxel
nexxel•3y ago
done done done
Sean Cassiere
Sean CassiereOP•3y ago
Noiceeeeeeeee
Want results from more Discord servers?
Add your server