8000 Storybook Issues with v2 · Issue #757 · 47ng/nuqs · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
Storybook Issues with v2 #757
Open
Open
@timheerwagen

Description

@timheerwagen

Context

What's your version of nuqs?

^2.1.1

What framework are you using?

  • ✅ Next.js (app router)
  • ✅ Next.js (pages router)

Which version of your framework are you using?

^14.2.9 and ^15.0.3 tested

Description

If i try to use nuqs in Storybook i get following errors:
import { NuqsAdapter } from "nuqs/adapters/next";
image

import { NuqsAdapter } from "nuqs/adapters/next/pages";
image

I have not specified app router. If i use import { NuqsAdapter } from "nuqs/adapters/react"; everything works fine.
I use the adapter inside a decorator in the preview.js file.

const preview = {
  decorators: [
    (Story) => (
      <NuqsAdapter>
        <Story />
      </NuqsAdapter>
    ),
  ],
};

My main.js includes

  framework: {
    name: "@storybook/nextjs",
    options: {},
  },

Reproduction

Codesandbox: https://codesandbox.io/p/github/BhagirathiRohidas/storybook-nextjs/csb-w7fl7v/draft/quirky-andras
npm run storybook

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0