Skip to content
This repository has been archived by the owner on Jun 21, 2023. It is now read-only.

Commit

Permalink
Fix rewrite shape in Storybook (vercel#24827)
Browse files Browse the repository at this point in the history
This fixes a bug in `@next/plugin-storybook` caused by an update in the rewrite structure, solution was provided by @stefanprobst vercel#19345 (comment)

Secondary question: it would be awesome if someone at Next could help translating `preset.js` into TypeScript, this would catch those bugs immediately. I've tried in vercel#18367 but failed to build correctly.

## Bug

- [X] Related issues linked using `fixes #number` => parent issue is an umbrella of various small issues: vercel#19345
- [X] Integration tests added => reproduction is implemented in https://github.com/lbke/next-plugin-storybook-demo until the package is more stable
  • Loading branch information
eric-burel committed May 6, 2021
1 parent 9b77624 commit f3e5bb7
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/next-plugin-storybook/preset.js
Expand Up @@ -15,7 +15,7 @@ async function webpackFinal(config) {
target: 'server',
config: nextConfig,
buildId: 'storybook',
rewrites: [],
rewrites: { beforeFiles: [], afterFiles: [], fallback: [] },
})

config.plugins = [...config.plugins, ...nextWebpackConfig.plugins]
Expand Down

0 comments on commit f3e5bb7

Please sign in to comment.