Skip to content

Commit 78a155a

Browse files
committed
simplify and expand on documentation
1 parent 76546d2 commit 78a155a

File tree

8 files changed

+1697
-310
lines changed

8 files changed

+1697
-310
lines changed

CLAUDE.md

Lines changed: 40 additions & 61 deletions
Original file line numberDiff line numberDiff line change
@@ -2,84 +2,63 @@
22

33
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
44

5-
## Common Development Commands
6-
7-
### Initial Setup
5+
## Development Commands
86

97
```bash
8+
# Initial Setup
109
yarn install
1110
yarn build
12-
```
1311

14-
### Development
12+
# Development
13+
yarn dev # Watch all packages for changes
14+
yarn example # Run the expo example app with Storybook
1515

16-
```bash
17-
# Watch all packages for changes
18-
yarn dev
19-
20-
# Run the expo example app with Storybook
21-
yarn example
22-
```
16+
# Testing
17+
yarn test # Run unit tests across all packages
2318

24-
### Testing
25-
26-
```bash
27-
# Run unit tests across all packages
28-
yarn test
29-
30-
# Run tests in CI mode
31-
yarn test:ci
19+
# Code Quality
20+
yarn lint # Run ESLint across the codebase
3221

22+
# Documentation (from docs/ directory)
23+
cd docs
24+
yarn start # Start development server
25+
yarn build # Build documentation
26+
yarn serve # Serve built documentation
3327
```
3428

35-
### Linting and Code Quality
36-
37-
```bash
38-
# Run ESLint across the codebase
39-
yarn lint
40-
```
41-
42-
### Release Process
29+
## Architecture Overview
4330

44-
```bash
45-
# Version packages (maintainers only)
46-
yarn version-packages
31+
**Yarn workspaces monorepo** managed by Lerna containing React Native Storybook packages.
4732

48-
# Publish to npm
49-
yarn publish:latest # For stable releases
50-
yarn publish:next # For pre-releases
51-
yarn publish:alpha # For alpha releases
52-
```
33+
### Packages
5334

54-
## Architecture Overview
35+
**Apps**
5536

56-
This is a **Yarn workspaces monorepo** managed by Lerna containing React Native Storybook packages:
37+
- examples/expo-example - Expo example app showcasing Storybook
38+
- docs - Documentation site for Storybook React Native
5739

58-
### Core Packages
40+
**Core:**
5941

60-
- **@storybook/react-native** - Main package providing Storybook functionality for React Native
61-
- **@storybook/react-native-ui** - Full UI components for on-device Storybook
62-
- **@storybook/react-native-ui-lite** - Lightweight UI components
63-
- **@storybook/react-native-ui-common** - Shared UI components
64-
- **@storybook/react-native-theming** - Theming utilities
42+
- `@storybook/react-native` - Main package providing Storybook functionality
43+
- `@storybook/react-native-ui` - Full UI components for on-device Storybook
44+
- `@storybook/react-native-ui-lite` - Lightweight UI components
45+
- `@storybook/react-native-ui-common` - Shared UI components
46+
- `@storybook/react-native-theming` - Theming utilities
6547

66-
### On-Device Addons
48+
**On-Device Addons:**
6749

68-
- **@storybook/addon-ondevice-actions** - Log component interactions
69-
- **@storybook/addon-ondevice-backgrounds** - Change story backgrounds
70-
- **@storybook/addon-ondevice-controls** - Dynamically edit component props
71-
- **@storybook/addon-ondevice-notes** - Add markdown documentation to stories
50+
- `@storybook/addon-ondevice-actions` - Log component interactions
51+
- `@storybook/addon-ondevice-backgrounds` - Change story backgrounds
52+
- `@storybook/addon-ondevice-controls` - Dynamically edit component props
53+
- `@storybook/addon-ondevice-notes` - Add markdown documentation to stories
7254

73-
### Build System
55+
### Build System & Metro Configuration
7456

75-
- Uses **tsup** for TypeScript compilation
76-
- Targets ES2022 with CommonJS output
57+
- Uses **tsup** for TypeScript compilation (ES2022, CommonJS output)
7758
- Each package has its own `tsup.config.ts`
78-
- Running `yarn prepare` in a package builds it
79-
80-
### Metro Configuration
59+
- `yarn prepare` in a package builds it
8160

82-
The `withStorybook` wrapper is crucial for React Native Storybook:
61+
The `withStorybook` Metro wrapper:
8362

8463
- Enables `unstable_allowRequireContext` for dynamic story imports
8564
- Automatically generates `storybook.requires.ts` file
@@ -88,8 +67,8 @@ The `withStorybook` wrapper is crucial for React Native Storybook:
8867

8968
### Key Concepts
9069

91-
1. **CSF (Component Story Format)**: Standard story syntax used across Storybook
92-
2. **On-device UI**: Native UI that runs directly on mobile devices
93-
3. **Story requires generation**: Automatic generation of story imports via Metro
94-
4. **Portable stories**: Reuse stories in unit tests
95-
5. **WebSocket support**: Remote control stories from external devices
70+
1. **CSF (Component Story Format)** - Standard story syntax
71+
2. **On-device UI** - Native UI that runs directly on mobile devices
72+
3. **Story requires generation** - Automatic generation of story imports via Metro
73+
4. **Portable stories** - Reuse stories in unit tests
74+
5. **WebSocket support** - Remote control stories from external devices

0 commit comments

Comments
 (0)