How to use the @storybook/preact.configure function in @storybook/preact

To help you get started, we’ve selected a few @storybook/preact examples, based on popular ways it is used in public projects.

Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.

github storybookjs / storybook / lib / cli / generators / PREACT / template-csf / .storybook / config.js View on Github external
import { configure } from '@storybook/preact';

// automatically import all files ending in *.stories.js
configure(require.context('../stories', true, /\.stories\.js$/), module);
github jchn / preact-spectre / .storybook / config.js View on Github external
import { configure } from '@storybook/preact'

// automatically import all files ending in *.stories.js
const req = require.context('../src', true, /.stories.js$/)
function loadStories() {
  req.keys().forEach(filename => req(filename))
}

configure(loadStories, module)
github yuanqing / create-figma-plugin / packages / ui / .storybook / config.js View on Github external
addDecorator(function (Story) {
  return 
})

addParameters({
  options: {
    storySort: function (a, b) {
      return a[1].kind === b[1].kind
        ? 0
        : a[1].id.localeCompare(b[1].id, undefined, { numeric: true })
    }
  }
})

configure(require.context('../src', true, /\.stories\.js$/), module)

@storybook/preact

Storybook Preact renderer

MIT
Latest version published 3 days ago

Package Health Score

95 / 100
Full package analysis