From 9d37dfffdc8ff3f7785cb64eb720f3874f9b1cb3 Mon Sep 17 00:00:00 2001 From: ymc9 <104139426+ymc9@users.noreply.github.com> Date: Thu, 7 Nov 2024 16:55:48 -0800 Subject: [PATCH 1/2] docs: add FAQ to tanstack-query --- docs/reference/plugins/tanstack-query.mdx | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/docs/reference/plugins/tanstack-query.mdx b/docs/reference/plugins/tanstack-query.mdx index 2aa265f0..79508b27 100644 --- a/docs/reference/plugins/tanstack-query.mdx +++ b/docs/reference/plugins/tanstack-query.mdx @@ -677,3 +677,15 @@ will be: ``` You can use the generated `getQueryKey` function to compute it. + +## FAQ + +### Next.js error "createContext" is not a function + +If you see an error like: + +```plain +Error in Next.js: "TypeError: (0 , react__WEBPACK_IMPORTED_MODULE_0__.createContext) is not a function" +``` + +It's usually due to you're using the hooks in a React server component. Make sure to add the `'use client;'` directive at the top of your component file. From 24a92b1b6a090779891eb84504dfe64a23fe2420 Mon Sep 17 00:00:00 2001 From: ymc9 <104139426+ymc9@users.noreply.github.com> Date: Wed, 13 Nov 2024 12:55:04 -0800 Subject: [PATCH 2/2] docs: update related to Hono --- docs/guides/edge.md | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/docs/guides/edge.md b/docs/guides/edge.md index 72f87c8e..00e00e0d 100644 --- a/docs/guides/edge.md +++ b/docs/guides/edge.md @@ -123,4 +123,5 @@ export default { Cloudflare's [D1 database](https://developers.cloudflare.com/d1/) is not yet supported by ZenStack due to its lack of support for interactive transactions. ::: -ZenStack currently doesn't have adapters for edge-first server frameworks like [hono](https://hono.dev/). Please create a [feature request](https://github.com/zenstackhq/zenstack/issues/new?template=feature_request.md&title=%5BFeature+Request%5D) if you have a need for it. +If you need a more sophisticated backend running on Cloudflare Workers, [Hono](https://hono.dev/) is a great choice. Check [how you can use ZenStack with Hono](https://zenstack.dev/docs/reference/server-adapters/hono). +``` \ No newline at end of file