tRPCttRPC
Powered by
TimeT
tRPC•2y ago•
2 replies
Time

Getting strange react error in nextjs

I am getting a strange Error Message when nextjs tries to compile:

TypeError: react__WEBPACK_IMPORTED_MODULE_1__.useContext is not a function
    at Config (./src/components/developer/config.tsx:13:80)
    at stringify (<anonymous>)
    at stringify (<anonymous>)
    at AsyncLocalStorage.run (node:async_hooks:346:14)
digest: "1302885403"
TypeError: react__WEBPACK_IMPORTED_MODULE_1__.useContext is not a function
    at Config (./src/components/developer/config.tsx:13:80)
    at stringify (<anonymous>)
    at stringify (<anonymous>)
    at AsyncLocalStorage.run (node:async_hooks:346:14)
digest: "1302885403"


it happends if i try:
const roles = trpc.snowflake.roles.useQuery();
const roles = trpc.snowflake.roles.useQuery();

the error message in browser is:
image.png
tRPCJoin
Move Fast & Break Nothing. End-to-end typesafe APIs made easy.
5,015Members
Resources

Similar Threads

Was this page helpful?
Recent Announcements

Similar Threads

TRPC with react query, getting error twice?
DevThoughtsDDevThoughts / ❓-help
3y ago
Nextjs, Expo react native, Trpc Help
GeekydevGGeekydev / ❓-help
7mo ago
Error while creating a mutation in NextJS
TarkyTTarky / ❓-help
3y ago
Error on NextJs AppRouter
sudoSsudo / ❓-help
2y ago