mirror of
https://github.com/storybookjs/storybook.git
synced 2025-04-04 22:11:15 +08:00
13 lines
340 B
JavaScript
13 lines
340 B
JavaScript
import { configure } from '@storybook/react';
|
|
|
|
// The simplest version of examples would just export this function for users to use
|
|
function importAll(context) {
|
|
context.keys().forEach(filename => context(filename));
|
|
}
|
|
|
|
function loadStories() {
|
|
importAll(require.context('./stories', true, /\.js$/));
|
|
}
|
|
|
|
configure(loadStories, module);
|