0.0.1 ā€¢ Published 3 years ago

pura-a-bolo v0.0.1

Weekly downloads
-
License
-
Repository
-
Last release
3 years ago

Storybook Example

You can use Storybook to test and share your component library quickly and easily! This example shows how to use Expo modules with Storybook CLI and Expo CLI.

This is setup as Storybook with Expo, instead of Expo with Storybook. This means that it's a dedicated RN app for Storybook, instead of attaching a Storybook instance to your current app (if you have one). If you have a pre-existing app setup with Expo, you could setup Storybook in the same project. This is setup to be separate, for something like a design system.

Getting Started

  1. yarn - Install dependencies
  2. yarn web - Run Storybook

Running on Native Devices

  1. yarn start - Start Expo in browser (should open a new tab)
  2. Wait for app to bundle. This may take 30+ seconds.
  3. Use QR code from Expo to open app on testing device (or press i to open simulator if available)

šŸ“ File Structure

Storybook with Expo CLI
ā”œā”€ā”€ stories
ā”‚   ā”œā”€ā”€ index.js āž”ļø Native story imports
ā”‚   ā””ā”€ā”€ Example.stories.js āž”ļø A Storybook page to render
ā”œā”€ā”€ assets āž”ļø All static assets for your project
ā”œā”€ā”€ App.tsx āž”ļø Entry Point for universal Expo apps
ā”œā”€ā”€ app.config.js āž”ļø Expo config file
ā””ā”€ā”€ babel.config.js āž”ļø Babel config (should be using `babel-preset-expo`)

šŸ“ Notes