Skip to content

Commit

Permalink
Merge pull request #28992 from storybookjs/valentin/fix-wrong-nextjs-…
Browse files Browse the repository at this point in the history
…framework-reference

Next.js: Fix wrong Next.js framework reference
  • Loading branch information
valentinpalkovic authored Aug 30, 2024
2 parents 69a737f + ccc136c commit 849fb20
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
@@ -1,10 +1,11 @@
// We need this import to be a singleton, and because it's used in multiple entrypoints
// both in ESM and CJS, importing it via the package name instead of having a local import
// is the only way to achieve it actually being a singleton
import { fn } from '@storybook/test';

// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore we must ignore types here as during compilation they are not generated yet
import { headers } from '@storybook/nextjs/headers.mock';
import { fn } from '@storybook/test';
import { headers } from '@storybook/experimental-nextjs-vite/headers.mock';

import { RequestCookies } from 'next/dist/compiled/@edge-runtime/cookies';

Expand Down
1 change: 0 additions & 1 deletion code/frameworks/nextjs/src/preview.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@ import type { Addon_DecoratorFunction, Addon_LoaderFunction } from 'storybook/in
// is the only way to achieve it actually being a singleton
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore we must ignore types here as during compilation they are not generated yet
import { cookies, headers } from '@storybook/nextjs/headers.mock';
// eslint-disable-next-line @typescript-eslint/ban-ts-comment
// @ts-ignore we must ignore types here as during compilation they are not generated yet
import { createNavigation } from '@storybook/nextjs/navigation.mock';
Expand Down

0 comments on commit 849fb20

Please sign in to comment.