File size: 684 Bytes
1e92f2d
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
import { configure, addDecorator, addParameters } from '@storybook/react';
import { withKnobs } from '@storybook/addon-knobs';
import { withA11y } from '@storybook/addon-a11y';
import { create } from '@storybook/theming';

addParameters({
  options: {
    panelPosition: 'right',
    theme: create({
      base: 'light',
      brandTitle: 'react-instantsearch',
      brandUrl: 'https://github.com/algolia/react-instantsearch',
    }),
  },
});

addDecorator(withKnobs);
addDecorator(withA11y);

const req = require.context('../stories', true, /\.stories\.(js|ts|tsx)$/);

function loadStories() {
  req.keys().forEach((filename) => req(filename));
}

configure(loadStories, module);