generated from nishkohli96/rn-template
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* first commit * name change wip * ios run successful * add husky * wip * clipboard & pressable * rn-config * rn-action-view * rn-contacts to start * wip * rn-contacts done * wip * razorpay done * permissions screen * location wip * wip * ios-permissions wip * rm rn-permissions * geolocation svc done * update README * minor changes * minor changes * intial setup android * fixes after merge * razorpay now works * getcontacts wip * contacts android done * location & contacts done * remove unused libs * remove netinfo * run prettier * ios app start changes Co-authored-by: nish <[email protected]>
- Loading branch information
1 parent
e71943c
commit 630798e
Showing
138 changed files
with
1,270 additions
and
357 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,5 @@ | ||
{ | ||
"presets": ["module:metro-react-native-babel-preset"], | ||
"plugins": [ | ||
[ | ||
"module-resolver", | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
SOME_ENV_KEY=THis_is_a_text_from_.env_file | ||
|
||
RAZORPAY_SANDBOX_KEY=rzp_test_blablabla | ||
|
||
RAZORPAY_SANDBOX_SECRET=I_WONT_TELL_YOU |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,21 @@ | ||
module.exports = { | ||
root: true, | ||
extends: '@react-native-community', | ||
env: { | ||
browser: true, | ||
es2021: true, | ||
}, | ||
extends: ['eslint:recommended', 'plugin:react/recommended'], | ||
parserOptions: { | ||
ecmaFeatures: { | ||
jsx: true, | ||
}, | ||
ecmaVersion: 12, | ||
sourceType: 'module', | ||
}, | ||
plugins: ['react'], | ||
rules: { | ||
indent: ['error', 'tab'], | ||
'linebreak-style': ['error', 'unix'], | ||
quotes: ['error', 'single'], | ||
semi: ['error', 'always'], | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,41 +1,47 @@ | ||
# RnTemplate | ||
# react-native-libs | ||
|
||
**"An Ideal app-template to start your next `react-native` project."** | ||
|
||
## Features | ||
|
||
- Project code properly organized, and using `alias-imports`. | ||
- Implemented Onboarding-screen. | ||
- Stack, Tab and Drawer Navigation. | ||
- Global state management using `mobx-react-lite`. | ||
- Support for theme and language change. | ||
- Added custom Google-font (Poppins). | ||
- Added relevant links for easier & time-saving app development under the **Developer-Guide** section. | ||
**"One or more of the used libraries would be a must in your next `react-native` project"** | ||
|
||
## Developer Guide | ||
|
||
- To create react-native-app with custom package name, do a project-wide find and replace ```com.awesomeproject → com.mycompany.myapp``` Also in the `android` directory, | ||
```src/main/java/com/awesomeproject → src/main/java/com/mycompany/myapp``` | ||
- Read the document of [react-native-config](https://www.npmjs.com/package/react-native-config) to use .env files based upon the shell. For running android app in windows, I used `SET ENVFILE=.env.staging && react-native run-android`. | ||
|
||
- Generate your app Icon using [MakeAppIcon](https://makeappicon.com/).Read More about app icon setup on this [Link](https://aboutreact.com/react-native-change-app-icon/).iOS icons can be generated using `Icon Set Creater` app available on the App Store. Make sure to also provide a round icon with the name `ic_launcher_round.png` in your android folder for various `mipmap-` directories. | ||
Go to [easyappicon.com](https://easyappicon.com/). | ||
Go to [easyappicon.com](https://easyappicon.com/). | ||
|
||
- Import this statement at the topmost line of your root as per `react-navigation` docs. | ||
```import 'react-native-gesture-handler';``` | ||
- Import this statement at the topmost line of your root as per `react-navigation` docs. | ||
`import 'react-native-gesture-handler';` | ||
|
||
- Enable Hermes [link](https://reactnative.dev/docs/hermes) | ||
|
||
- To make sure that the content doesn't overlap, especially in iPhones, use `SafeAreaProvider`. Import this stmt at the top of your app code. | ||
```import { SafeAreaProvider } from 'react-native-safe-area-context';``` | ||
`import { SafeAreaProvider } from 'react-native-safe-area-context';` | ||
|
||
- Install [Async Storage](https://react-native-async-storage.github.io/async-storage/). Needs to be manually linked. Go to [this thread](https://stackoverflow.com/questions/61479644/invalid-podfile-file-unable-to-locate-the-executable-node) if `npx pod-install` fails to run. | ||
|
||
- Dependencies for `@react-navigation/stack` -> `react-native-safe-area-context`, `react-native-gesture-handler`. Run `npx pod-install` after installing the dependencies. | ||
|
||
- Using `react-native-reanimated` v-1.13.3 as v2 was not working fine. | ||
- Using `react-native-reanimated` v-1.13.3 as v2 was not working fine. | ||
|
||
- Manually link `react-native-vector-icons` in ios [link](https://medium.com/@vimniky/how-to-use-vector-icons-in-your-react-native-project-8212ac6a8f06). Check [this link](https://medium.com/@danielskripnik/how-to-add-and-remove-custom-fonts-in-react-native-b2830084b0e4) to add/remove fonts. | ||
|
||
## Main Libraries Used | ||
|
||
- [@react-native-community/clipboard](https://www.npmjs.com/package/@react-native-community/clipboard) | ||
- [react-native-config](https://www.npmjs.com/package/react-native-config) | ||
- [react-native-contacts](https://www.npmjs.com/package/react-native-contacts) | ||
- [react-native-geolocation-service](https://www.npmjs.com/package/react-native-geolocation-service) | ||
- [react-native-razorpay](https://www.npmjs.com/package/react-native-razorpay) | ||
|
||
# Other Libaries not used here | ||
|
||
- Manually link `react-native-vector-icons` in ios [link](https://medium.com/@vimniky/how-to-use-vector-icons-in-your-react-native-project-8212ac6a8f06). Check [this link](https://medium.com/@danielskripnik/how-to-add-and-remove-custom-fonts-in-react-native-b2830084b0e4) to add/remove fonts. | ||
- [@react-native-community/cameraroll](https://www.npmjs.com/package/@react-native-community/cameraroll) | ||
- [react-native-autogrow-textinput](https://www.npmjs.com/package/react-native-autogrow-textinput) | ||
- [react-native-calendars](https://www.npmjs.com/package/react-native-calendars) | ||
- [react-native-calendar-events](https://www.npmjs.com/package/react-native-calendar-events) | ||
- [react-native-camera-kit](https://www.npmjs.com/package/react-native-camera-kit) | ||
- [react-native-netinfo](https://www.npmjs.com/package/react-native-netinfo) | ||
|
||
# Support Me | ||
|
||
If you found this template helpful and saved your valuable time, consider [buying me a coffee](https://www.buymeacoffee.com/nish1896) | ||
If you learnt something new and found this project helpful, consider [buying me a coffee](https://www.buymeacoffee.com/nish1896) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,3 @@ | ||
<resources> | ||
<string name="app_name">RnTemplate</string> | ||
<string name="app_name">ReactNativeLibs</string> | ||
</resources> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,9 @@ | ||
rootProject.name = 'RnTemplate' | ||
rootProject.name = 'ReactNativeLibs' | ||
apply from: file("../node_modules/@react-native-community/cli-platform-android/native_modules.gradle"); applyNativeModulesSettingsGradle(settings) | ||
include ':app' | ||
|
||
include ':react-native-razorpay' | ||
project(':react-native-razorpay').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-razorpay/android') | ||
|
||
include ':react-native-contacts' | ||
project(':react-native-contacts').projectDir = new File(rootProject.projectDir, '../node_modules/react-native-contacts/android') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
{ | ||
"name": "RnTemplate", | ||
"displayName": "RnTemplate" | ||
"name": "ReactNativeLibs", | ||
"displayName": "ReactNativeLibs" | ||
} |
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
export default Dark = { | ||
dark: true, | ||
colors: { | ||
primary: '#ff5071', /* pinkish-red */ | ||
background: '#25293e', /* darkbluish black */ | ||
card: '#008c8c', /* maars-green */ | ||
text: '#f7f6f3', /* soft-white */ | ||
border: '#959fa8', /* light-gray */ | ||
notification: '#8a79af', /* black-currant */ | ||
heading: '#fdd261', /* mango */ | ||
primary: '#ff5071' /* pinkish-red */, | ||
background: '#25293e' /* darkbluish black */, | ||
card: '#008c8c' /* maars-green */, | ||
text: '#f7f6f3' /* soft-white */, | ||
border: '#959fa8' /* light-gray */, | ||
notification: '#8a79af' /* black-currant */, | ||
heading: '#fdd261' /* mango */, | ||
}, | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,12 @@ | ||
export default Light = { | ||
dark: false, | ||
colors: { | ||
primary: '#008cd1', /* sky-blue */ | ||
background: '#f7f6f3', /* soft-white */ | ||
card: '#6d9773', /* soft-green */ | ||
text: '#25293e', /* soft black */ | ||
border: '#76777c', /* gray */ | ||
notification: '#8a79af', /* black-currant */ | ||
heading: '#04437d', /* dark-blue */ | ||
primary: '#008cd1' /* sky-blue */, | ||
background: '#f7f6f3' /* soft-white */, | ||
card: '#abcded' /* light sky-blue */, | ||
text: '#25293e' /* soft black */, | ||
border: '#76777c' /* gray */, | ||
notification: '#8a79af' /* black-currant */, | ||
heading: '#04437d' /* dark-blue */, | ||
}, | ||
}; |
Oops, something went wrong.