simya-react-native-commons
v0.1.7
Published
**Important Configurations** #gitlab-ci, flow, eslint, just & Metro Bundler (RN 0.57+) To apply in any project,
Downloads
5
Keywords
Readme
React Native Commons
Important Configurations #gitlab-ci, flow, eslint, just & Metro Bundler (RN 0.57+) To apply in any project,
- you need to create a stub for flow-type for react-native-commons and all sub-module to prevent it show error of can't resolved when import its as a library
- In folder flow-typed (of your project), create file names
react-native-commons_vx.x.x.js
- In react-native-commons_vx.x.x.js file, export the module (react-native-commons & the sub-modules you want to implement & import) like:
`declare module 'react-native-commons' { declare module.exports: any; }
declare module 'react-native-commons/app/about-us' { declare module.exports: any; }
declare module 'react-native-commons/app/cross-promotion' { declare module.exports: any; }`
- Use
yarn install
insteadnpm install
& delete the package-lock.json file (with yarn we don't need it anymore)