-
-
Notifications
You must be signed in to change notification settings - Fork 9.9k
Closed
Description
Is your feature request related to a problem? Please describe
I'm having trouble setup next/jest with storybook Import stories.
With jest-babel works as expected, migrating to next/jest it fails to import the config file.
Cannot find module '.storybook/preview' from 'setupFiles.js'
However, Jest was able to find:
'.storybook/preview.js'
You might want to include a file extension in your import, or update your 'moduleFileExtensions', which is currently ['js', 'mjs', 'cjs', 'jsx', 'ts', 'tsx', 'json', 'node'].
import * as globalStorybookConfig from './.storybook/preview';
When I remove this line it works, but cannot leverage the global config we need from the storybook.
here is the repro repo based on the with-jest and with-jest-babel examples.
Describe the solution you'd like
I want at least some documentation how to setup.
Describe alternatives you've considered
No response
Are you able to assist to bring the feature to reality?
yes, I can
Additional context
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Type
Projects
Status
Done