mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-07 23:22:10 +08:00
487 B
487 B
export async function webpack(baseConfig, options) {
// Modify or replace config.
// Mutating the original reference object can cause unexpected bugs,
// so in this example we replace.
const { module = {} } = baseConfig;
return {
...baseConfig,
module: {
...module,
rules: [
...(module.rules || []),
{
/* some new loader */
},
],
},
};
}