- Persisted log in and log out.
- Typescript code and testing.
- State management with Redux Toolkit.
- HTTP client with error interceptor with axios.
- Screen navigation with React Navigation.
- Redux Reducers and Async Action unit testing with Jest.
- E2E testing with Detox.
- React Native CLI
npm install
- Start Metro:
npm start
- In other terminal depending the desired platform execute:
- iOS:
npm run ios
- Android:
npm run android
npm install detox --save-dev
npm test
- Start Metro:
npm run test:start
- Open other terminal and execute:
build:e2e:ios
test:e2e:ios
- Start Metro:
npm run test:start
- Open other terminal and execute:
build:e2e:android
test:e2e:android
react-app-login
├── app
│ ├── App.tsx
│ ├── models
│ ├── redux
│ ├── screens
│ ├── services
├── ___tests___
├── e2e
├── jest
├── demo
├── android
├── ios
├── index.js
└── package.json
App.tsx The main App component.
models This is where the app models are stored.
redux Directory with Redux slices and Redux configuration.
screens This is where the screens components are stored.
services Here are the API services and the HTTP configuration.
This is where the components tests are saved.
Here are the end to end testing files.
This is were jest configurations are stored.
test
Runs the app unit tests with Jest.
test:start
Starts metro replacing the '.ts' files with '.e2e.ts' files for Detox file mocking.
build:e2e:android
Builds the Detox Android project.
build:e2e:ios
Builds the Detox iOS project.
test:e2e:android
Runs the Detox tests in android emulator.
test:e2e:ios
Runs the iOS tests in iOS simulator.