storybook-react-native-web-rsbuild
v3.2.0
Published
Storybook for React Native Web and Rsbuild: Develop React Native components for web in isolation with Hot Reloading.
Maintainers
Readme
storybook-react-native-web-rsbuild
Storybook for React Native Web and Rsbuild: Develop React Native components for web in isolation with Hot Reloading.
Installation
npm install storybook-react-native-web-rsbuild react-native-webUsage
In your .storybook/main.ts:
import type { StorybookConfig } from 'storybook-react-native-web-rsbuild'
const config: StorybookConfig = {
stories: ['../src/**/*.stories.@(js|jsx|ts|tsx)'],
addons: ['@storybook/addon-docs'],
framework: {
name: 'storybook-react-native-web-rsbuild',
options: {},
},
}
export default configFramework Options
modulesToTranspile
Many React Native packages ship untranspiled code. Use this option to add additional packages that need transpilation:
framework: {
name: 'storybook-react-native-web-rsbuild',
options: {
modulesToTranspile: ['react-native-reanimated', 'nativewind'],
},
}By default, packages starting with react-native, @react-native, expo, and @expo are already included.
Features
- Full React Native Web support with Rsbuild
- Aliases
react-nativetoreact-native-webautomatically - Handles untranspiled React Native packages
- Supports Flow syntax in React Native packages
- Compatible with Expo projects
License
MIT
