Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: expo should now work with apha #262

Merged
merged 1 commit into from
Sep 12, 2021
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 12 additions & 10 deletions v6README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

**Vanilla React Native:** Run the [setup script](https://gist.github.com/dannyhw/9b84973dcc6ff4fa2e86e32d571d294e) or follow this guide to do it step-by-step.

**Expo:** Follow this guide.
**Expo:** Run the [expo setup script](https://gist.github.com/dannyhw/92b3ff0d6ccaead9df2820a507154b87) or follow this guide to do it step-by-step.

This guide assumes that you have yarn, node, npm and npx and they are in your path so your
terminal can run them. The guide is for Mac/Linux, Windows might need slight adjustments. Contributions for a Windows guide are welcome!
Expand Down Expand Up @@ -54,15 +54,16 @@ yarn add @storybook/react-native@next \
For Expo, we need to separately install the react native packages so Expo can maintain the compatibility for us.

```shell
yarn add @storybook/react-native@next \
@storybook/addon-ondevice-actions@next \
@storybook/addon-ondevice-controls@next \
@storybook/addon-ondevice-backgrounds@next \
@storybook/addon-ondevice-notes@next \
@storybook/addon-actions \
@storybook/addon-controls

expo install @react-native-async-storage/async-storage @react-native-community/datetimepicker @react-native-community/slider
expo install @storybook/react-native@next \
@storybook/addon-ondevice-actions@next \
@storybook/addon-ondevice-controls@next \
@storybook/addon-ondevice-backgrounds@next \
@storybook/addon-ondevice-notes@next \
@storybook/addon-actions \
@storybook/addon-controls \
@react-native-async-storage/async-storage \
@react-native-community/datetimepicker \
@react-native-community/slider
```

Datetime picker, slider and addon-controls are required for controls to work. If you don't want controls you don't need to install these (controls is the knobs replacement).
Expand Down Expand Up @@ -112,6 +113,7 @@ defaultConfig.transformer.getTransformOptions = async () => ({
inlineRequires: false,
},
});
defaultConfig.watchFolders = [...defaultConfig.watchFolders, './.storybook'];
module.exports = defaultConfig;
" > metro.config.js;
```
Expand Down