We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
hello. As you can see in the screenshot, parameters.fileName is null. Add-ons that depend on'fileName' won't work. (e.g. storybook-addon-playwright )
parameters.fileName
story source
const Template: ComponentStory<typeof Button> = function (args) { console.log(arguments); return <Button {...args} />; };
I have patched codegen-iframe-script.js as follows.
codegen-iframe-script.js
add this code in line 56.
const cwd = process.cwd(); const resolveMap = storyEntries.reduce((prev, entry) => ({...prev, [entry]: entry.replace(cwd, '.') }), {}); const modules = storyEntries.map((entry, i) => `${JSON.stringify(entry)}: story_${i}`).join(',') const loadable = ` (() => { const loadable = function(key) { return {${modules}}[key]; }; Object.assign(loadable, { keys: () => (${JSON.stringify(Object.keys(resolveMap))}), resolve: (key) => (${JSON.stringify(resolveMap)}[key]) }); return loadable; })()`;
change line 112.
configure(${loadable}, { hot: import.meta.hot }, false); // not sure if the import.meta.hot thing is correct `.trim(); return code; };
The text was updated successfully, but these errors were encountered:
While this is still broken when storyStoreV7 is not enabled. When it is enabled it works as expected :)
Sorry, something went wrong.
Successfully merging a pull request may close this issue.
hello.
As you can see in the screenshot,
parameters.fileName
is null.Add-ons that depend on'fileName' won't work.
(e.g. storybook-addon-playwright )
story source
I have patched
codegen-iframe-script.js
as follows.add this code in line 56.
change line 112.
The text was updated successfully, but these errors were encountered: