Skip to content

Commit

Permalink
Refactor preset.ts to use 'framework' instead of 'presetFramework' va…
Browse files Browse the repository at this point in the history
…riable
  • Loading branch information
valentinpalkovic committed Jan 26, 2024
1 parent ec359a4 commit dec75ae
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions code/frameworks/react-webpack5/src/preset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,13 +10,13 @@ export const addons: PresetProperty<'addons'> = [
];

export const core: PresetProperty<'core'> = async (config, options) => {
const presetFramework = await options.presets.apply('framework');
const framework = await options.presets.apply('framework');

return {
...config,
builder: {
name: getAbsolutePath('@storybook/builder-webpack5'),
options: typeof presetFramework === 'string' ? {} : presetFramework.options.builder || {},
options: typeof framework === 'string' ? {} : framework.options.builder || {},
},
renderer: getAbsolutePath('@storybook/react'),
};
Expand Down

0 comments on commit dec75ae

Please sign in to comment.