Skip to content

How to use searchParamsCache.all in storybook with next appDirectory #738

Answered by franky47
stevejcox asked this question in Q&A
Discussion options

You must be logged in to vote

Thanks for the report, I managed to reproduce it, but the error goes away when using the sync version of the searchParams page prop (like it was in Next 14 and below).

When using the Promise-based API (for Next 15), I get another error from Storybook, even when using features.experimentalRSC: true in the Storybook config:

async/await is not yet supported in Client Components, only Server Components. This error is often caused by accidentally adding `'use client'` to a module that was originally written for the server.

Edit: see #740.

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by franky47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants