question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

@storybook/addon-info not working

See original GitHub issue

Describe the bug Just installed @storybook/addon-info. When following the instruction in the readme I either get No Preview or it’s stuck in the loading state (see screenshot). Nothing in the console to say there is an error.

Expected behavior Could I get instruction on how to fix?

Screenshots image

Code snippets

When trying to do it on a Component for which I get No Preview ` import React from ‘react’; import { storiesOf, addDecorator } from ‘@storybook/react’; import { withA11y } from ‘@storybook/addon-a11y’; import { withInfo } from ‘@storybook/addon-info’;

import StandardAction from ‘./StandardAction’;

addDecorator(withA11y);

storiesOf(‘Navigation|Buttons’, module) .addDecorator(withInfo) .add(‘Standard Action’, () => ( <StandardAction label="label" /> ), { info: ‘☹️ no emojis’ }, ); @storybook/addon-a11y”: “^5.0.10”, “@storybook/addon-actions”: “^5.0.10”, “@storybook/addon-info”: “^5.0.10”, “@storybook/addon-links”: “^5.0.10”, “@storybook/addons”: “^5.0.10”, “@storybook/react”: “^5.0.10”, `

For when I’m trying to do it globally and it gets stuck in Loading state config.js `import { configure } from ‘@storybook/react’; import { withInfo } from ‘@storybook/addon-info’;

import ‘…/src/index.scss’;

addDecorator(withInfo);

function loadStories() { require(‘…/src/atoms/StandardAction/StandardAction.stories’); require(‘…/src/atoms/NoNav/NoNav.stories’); require(‘…/src/atoms/SelectListInput/SelectListInput.stories’); require(‘…/src/atoms/Container/Container.stories’); }

configure(loadStories, module);`

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Reactions:1
  • Comments:10 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
mlmasseycommented, May 3, 2019

@palmerminto @shilman I’m having the same issue. Basically, when I’m importing withInfo as import {withInfo} from '@storybook/addon-info' I immediately see that the left panel never loads and the cursor continually shows loading. Basically, if I never import withInfo, everything works fine. I’m running Storybook 5.0.11. On a side note, I’m running React 16.3, so not sure if that is what is causing the problem. I cannot upgrade to a higher version due to our code base. As noted above though, Storybook/withInfo should not be dependent on newer versions or React.

1reaction
palmermintocommented, Apr 25, 2019

hey @devina91, Could you open a new issue - you’ll probably get a more focused solution? I’m going to close this.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Storybook Info Addon
Storybook Info Addon will show additional information for your stories in Storybook. Useful when you want to display usage or other types of...
Read more >
Failed to load preset: "@storybook/addon-info" on level 1
this problem occurs after I installing prop-types in my create-react-app project. the error message is as follows: Can someone tell me where the ......
Read more >
storybook/addon-info - CodeSandbox
A Storybook addon to show additional information for your stories. 0. 572.
Read more >
React Storybook Info Addon - Daily Javascript
If you are not familiar with Storybook yet, it provides you with an isolated environment to create your React components in. Over the...
Read more >
Storybook Docs with mdx support and addon knobs - Medium
Okay, not bad, everything seems to be working after that. Docs addon. Next, I try to make sense of the new docs addon,...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found