rn-devdesign-system-demo
v0.1.14
Published
Design System for RN Apps
Downloads
108
Readme
Contributing to the library -
- Clone the repository
https://github.com/rushi-173/rn-devdesign-system-demo/tree/setting-up-storybook
- Enter into repository
cd rn-devdesign-system-demo
yarn install
yarn compile
- compile commands different for diff device at stage
- if prev lib exists
- windows
rd /s /q lib && tsc -p .
- ios
rm -rf lib && tsc -p .
- windows
- if not
tsc -p .
cd example
- Install dependencies for example app -
yarn install
- Start example app
yarn start
- In another terminal at
/example
doyarn android
to see your app running inside the emulator.- Now you are able to see storybook react native running which is using components from component library
- If you are facing error about
Invalid hook call
-- go to
rn-devdesign-system-demo/lib
and donpm link ../example/node_modules/react
(to link both library and app to single react intance)
- go to
- if you want to see app just comment the code which exported storybook from
example/index.js
and uncomment appregistry code and reload and you will be able to see your app running.
- Now go back to the library
cd ..
- Create a new component in
src/atomic-components
- Export from
src/index.tsx
- Now again compile the library use
yarn compile
- Import that component in example app from library and use it. Save your app and just reload if its already running or start the app