- Clone the project:
git clone https://github.com/shaunsaker/covid-19-south-africa-app.git
- Install npm dependencies:
yarn
- Install pods:
cd ios
pod install
-
Add your Firebase* config files to
./ios/GoogleService-Info.plist
and./android/app/google-services.json
. -
Run the app:
yarn ios
yarn android
The project uses Firebase for it's backend. To get the app running locally you will need to:
-
Create a project in Firebase.
-
Enable the Cloud Firestore.
-
Add data to the Cloud Firestore with the following schema:
type DateField = string; // e.g. 2020-04-01T17:20:27.038Z
type DocumentId = string; // e.g. 02-04-2020
interface DocumentBase {
dateAdded: DateField;
dateCreated: DateField;
href: string;
}
interface ConfirmedCaseDocument extends DocumentBase {
confirmedCases: number;
}
interface DeathCaseDocument extends DocumentBase {
deaths: number;
}
interface RecoveryCaseDocument extends DocumentBase {
recovered: number;
}
interface TestCaseDocument extends DocumentBase {
tests: number;
}
interface Collections {
confirmedCases: {
[key: DocumentId]: ConfirmedCaseDocument;
};
deathCases: {
[key: DocumentId]: DeathCasesDocument;
};
recoveries: {
[key: DocumentId]: RecoveryCaseDocument;
};
tests: {
[key: DocumentId]: TestCaseDocument;
};
}