A React Native mobile application for scanning QR codes and verifying attendee eligibility at the Rwanda Mining Week event.
- QR Code Scanning: Scan QR codes or IDs to verify attendee status
- Real-time Verification: Check against mock database for eligibility
- Admin Dashboard: View statistics and recent scans
- Modern UI: Clean, Rwanda-themed design with TailwindCSS
- Mock Data: Simulated attendee, sponsor, and exhibitor data
- React Native with Expo
- TailwindCSS via NativeWind
- React Navigation (Stack + Tab navigation)
- Expo Barcode Scanner for QR code scanning
- Zustand for state management
- React Native SVG Charts for data visualization
- Node.js (v16 or higher)
- npm or yarn
- Expo CLI (
npm install -g @expo/cli
) - iOS Simulator (for iOS) or Android Studio (for Android)
-
Clone the repository
git clone <repository-url> cd RwandaMiningMobile
-
Install dependencies
npm install
-
Start the development server
npm start
-
Run on device/simulator
- Press
i
for iOS Simulator - Press
a
for Android Emulator - Scan QR code with Expo Go app on your phone
- Press
RwandaMiningMobile/
├── src/
│ ├── data/ # Mock JSON data files
│ ├── screens/ # React Native screens
│ ├── services/ # Data services and API calls
│ └── store/ # Zustand state management
├── assets/ # App icons and images
├── App.js # Main app component
├── package.json # Dependencies
├── app.json # Expo configuration
├── tailwind.config.js # TailwindCSS configuration
└── babel.config.js # Babel configuration
- Home Screen: Tap "Start Scanning" to begin
- Scanner Screen:
- Point camera at QR code
- Or use "Mock Scan" button for testing
- Result Screen: View attendee details and eligibility status
- Statistics: View total scans, valid/invalid counts
- Charts: Pie chart showing breakdown by role
- Recent Scans: List of last 10 scanned people
- Quick Actions: Start scanning or export data
The app includes mock data for testing:
- Attendees: 5 registered attendees
- Sponsors: 4 sponsors with different levels
- Exhibitors: 5 exhibitors with booth numbers
Valid IDs for testing:
ATT001
,ATT002
,ATT003
,ATT004
,ATT005
SPO001
,SPO002
,SPO003
,SPO004
EXH001
,EXH002
,EXH003
,EXH004
,EXH005
Invalid IDs for testing:
INVALID001
,TEST123
, or any other ID
Rwanda-themed colors are defined in tailwind.config.js
:
rwanda-green
: #1a5f3c (Primary green)rwanda-gold
: #f4c430 (Gold accent)rwanda-blue
: #0066cc (Blue accent)rwanda-red
: #ce1126 (Red accent)
Edit the JSON files in src/data/
to modify the mock database:
attendees.json
- Attendee datasponsors.json
- Sponsor dataexhibitors.json
- Exhibitor data
Replace the mock data service in src/services/dataService.js
with real API calls:
export const lookupPerson = async (scannedId) => {
try {
const response = await fetch(`https://your-api.com/attendees/${scannedId}`);
const data = await response.json();
return { success: true, data };
} catch (error) {
return {
success: false,
data: {
/* error data */
},
};
}
};
-
Camera Permission Denied
- The app will show a fallback screen with "Mock Scan" option
- Enable camera permissions in device settings
-
Metro Bundler Issues
npm start -- --clear
-
NativeWind Not Working
npm install nativewind@latest npx tailwindcss init
-
Expo Go Issues
- Make sure you have the latest Expo Go app
- Try clearing Expo Go cache
- Use the "Mock Scan" button for quick testing without camera
- Check the Dashboard tab to see scan history
- Use the "Clear All" button in Dashboard to reset data
- Pull to refresh on Dashboard to update statistics
- Configure app.json with your app details
- Add proper icons in the assets folder
- Build the app:
expo build:android # For Android expo build:ios # For iOS
This project is created for demonstration purposes. Feel free to modify and use for your own events.
For issues or questions:
- Check the troubleshooting section
- Review Expo documentation
- Check React Navigation documentation
- Verify all dependencies are properly installed