express-server/config.jsneeds to be created following the example fromexpress-server/config.js.sample.- To test locally, ensure
mobile/config.jshas the correct API address. It should point to the computer hosting the Express server on LAN.
To install dependencies: npm install in express-server
To run: npm start in express-server
To install dependencies: npm install in react-frontend
To run: npm start in react-frontend
The files are set up for React to proxy to backend server for API calls.
To install Expo:
npm i --global exponpm i --global expo-cli
To run: expo start (in mobile/)
- Focus on
App.tsx,api.ts,utils.ts,screens/, andcomponents/. - The
components/__tests__should be filled out properly but I haven't got there yet. - The navigation is done in
navigation/BottomTabNavigator.jsxvia some black magic. It's not too hard to figure out loosely what's going on by reading https://reactnavigation.org/docs/stack-navigator. screens/AuthorisationScreen.jsxwill be the one-time PIN flow.screens/PrescriptionsScreen.jsxcontains buttons (need to be styled properly) leading to "Current Prescriptions" as well as "Last Repeat". This flow can be sketched out in more detail tomorrow.