Skip to content
This repository has been archived by the owner on Mar 9, 2021. It is now read-only.

Failed to load bundle Storybook #259

Open
oktalk opened this issue Apr 5, 2019 · 1 comment
Open

Failed to load bundle Storybook #259

oktalk opened this issue Apr 5, 2019 · 1 comment

Comments

@oktalk
Copy link

oktalk commented Apr 5, 2019

I'm running into an issue with Storybook. Starting with a fresh install, running yarn storybook the build fails (truncated error log below). I was able to move on by following this thread: storybookjs/storybook#4179

Updating my package.json to "storybook": "storybook start -p 7007 --skip-packager | react-native start --projectRoot storybook" is working for now.

...
yarn run v1.15.2
$ storybook start -p 7007
=> Loading custom .babelrc from project directory.
=> Loading custom addons config.
=> Using default webpack setup based on "Create React App".
Scanning 1199 folders for symlinks in /Users/me/Development/projects/andross/node_modules (13ms)

React Native Storybook started on => http://localhost:7007/

error: unknown option `--projectRoots'
webpack built ab3d4c1e339e0b94f5e7 in 2675ms
Hash: ab3d4c1e339e0b94f5e7
Version: webpack 3.12.0
Time: 2675ms
...
...
ERROR in ./storybook/addons.js
Module build failed: Error: Couldn't find preset "module:metro-react-native-babel-preset" relative to directory "/Users/me/Development/projects/andross/storybook"
...
@kerematam
Copy link

kerematam commented Apr 14, 2019

I had same issue. I've solved by updating babel-core to 7.0.0-bridge.0 and use storybookSwitcher function for relaying storybook to UI.

In App.js file :

export default DebugConfig.useReactotron
  ? console.tron.storybookSwitcher(StorybookUI)(App)
  : App

Using storybookSwitcher function is not directly about your issue but anyway. This is how make storybook up and running after fresh install of Ignite Andross.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants