This is a new React Native project for React Native E-commerce Product Configurator Exercise, bootstrapped using @react-native-community/cli.
| Username | Admin |
|---|---|
| Babs | false |
| Lola | false |
| Macaulay | true |
| Jane | false |
| Doe | true |
For authentication, use the password 123456 with any of the names in the Employees table at the top of this README as username.
Clone the repository from GitHub using
git clone https://github.com/devbabs/easyteam-embed.git# Navigate to project folder
cd easyteam-embed
# Using npm
npm i
# Install all Pod dependencies for iOS
cd ios && pod install && cd ..Ensure you have a android/local.properties file with the following content:
# sdk.dir must contain the absolute path to your local sdk for android
sdk.dir=/Users/$(whoami)/Library/Android/sdkFirst, you will need to start Metro, the JavaScript bundler that ships with React Native.
To start Metro, run the following command from the root of your React Native project:
# using npm
npm startFollow these steps to add neccessary values in the root of the project.
- Create a file
.envin the root of the project - Add API_URL=https://easyteam-embed-backend.onrender.com
NB: https://easyteam-embed-backend.onrender.com is the backend for authentication
Let Metro Bundler run in its own terminal. Open a new terminal from the root of your React Native project. Run the following command to start your Android or iOS app:
# using npm
npm run android# using npm
npm run iosIf everything is set up correctly, you should see the app running in your Android Emulator or iOS Simulator shortly provided you have set up your emulator/simulator correctly.
This is one way to run your app — you can also run it directly from within Android Studio and Xcode respectively.
If you can't get this to work, see the Troubleshooting page.