update-addon-info.d.ts 593 B

123456789101112131415161718192021222324252627
  1. /**
  2. * Takes the deprecated addon-info API, addWithInfo, and
  3. * converts to the new withInfo API.
  4. *
  5. * Example of deprecated addWithInfo API:
  6. *
  7. * storiesOf('Button')
  8. * .addWithInfo(
  9. * 'story name',
  10. * 'Story description.',
  11. * () => (
  12. * <Button label="The Button" />
  13. * )
  14. * )
  15. *
  16. * Converts to the new withInfo API:
  17. *
  18. * storiesOf('Button')
  19. * .add('story name', withInfo(
  20. * 'Story description.'
  21. * )(() => (
  22. * <Button label="The Button" />
  23. * )))
  24. */
  25. declare function transformer(file: any, api: any): any;
  26. export { transformer as default };