Boda
is a react-native taxi app template.
BodaApp
Designed for android . Not yet developed for ios, but I'm working on updating it!
- Download with :
$ git clone https://github.com/code-ninja-james/BodaApp
-
mobile
-
In the BodaApp folder in your terminal
For npm run
$cd mobile && npm install
For yarn run
$cd mobile && yarn install
-
Google api key configuration
- In mobile folder using a code editor edit googleapikey.js
- In mobile/android/app/src/main/androidmanifest.xml change this
android:value="YourGoogleApiKey"/>
-
Backend and Frontend connect
- In mobile/baseUrl.js file change the ip adress to your server's internal ip adress don't change the port number
4000
- In mobile/screens folder in the Driver.js and Passenger.js change the ip adress for socket.io connection to you server internal ip adress don't change the port number
3000
- In mobile/baseUrl.js file change the ip adress to your server's internal ip adress don't change the port number
-
Change gradle files in your android folder
- The app won't work if the android files are not compatible with your environment
- Use android studio and stackoverflow for better debbugging
-
2.express-backend
-
In the BodaApp folder in your terminal
For npm run
$cd express-backend && npm install
For yarn run
$cd express-backend && yarn install
-
Create a database in MongoDbAtlas
-
In MongoDb Atlas create a cluster with one database and a user with read and write priveledges
-
Use a code editor preferrably vscode to edit config folder in express-backend
- In mongodb.js in config folder change this line
'mongodb+srv://YOUR_USERNAME_HERE:'+ encodeURIComponent('YOUR_PASSWORD_HERE') + '@CLUSTER_NAME_HERE.mongodb.net/test?retryWrites=true'
you can check here on how to do it correctly - In auth.js in config folder
const jwtSecret ="replace with any string";
- In mongodb.js in config folder change this line
-
1.Open an android emulator in the mobile folder run in your terminal
$react-native start
then
$react-native run-android
-
In the express-backend run
nodemon index.js
-
In the socket.io-backend run
nodemon index.js
- Clone repo and create a new branch:
$ git checkout https://github.com/code-ninja-james/BodaApp -b name_for_new_branch
- Make changes and test
- Submit Pull Request with comprehensive description of changes