set state action calls into default empty dispatch used to initialize createContext in TSX file #78444
-
SummaryI am new to the nextjs framework and Typescript, and currently using the Context mechanism to share global data, following examples online and Copilot. The code segments are as follows: @types\openai.d.ts:
context\StateContext.tsx:
app_app.tsx:
components\StartButton.tsx:
When I debug into I am using next.js v15 in VS Code IDE. Thanks Additional informationNo response ExampleNo response |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Hi, Are your using App Router, or Pages Router? Could you share a screenshot of your project's file system? It seems to be like you are using App Router, but you have tried to add In App Router, you'd need to wrap the |
Beta Was this translation helpful? Give feedback.
No worries! Please don't forget to also mark as answered :)