A minimalist compass application built with Expo React Native that uses device sensors to show magnetic north.
- Real-time compass with smooth needle rotation
- Minimalist design with black and white high contrast UI
- Large centered compass (250px diameter) for easy reading
- Cardinal directions (N, E, S, W) marked on compass face
- Digital heading display showing degrees (0-360°)
- Direction indicator showing N, NE, E, SE, S, SW, W, NW
- Magnetometer sensor integration for accurate orientation
- Built with Expo React Native
- Uses
expo-sensorsfor device magnetometer access - Updates every 100ms for smooth needle movement
- File-based routing with Expo Router
- TypeScript for type safety
-
Install dependencies
bun install
-
Start the app
bun start
-
Run on your device
- Scan QR code with Expo Go app
- Or use Android emulator/iOS simulator
The app uses the device's magnetometer sensor to detect magnetic fields and calculate the device's heading relative to magnetic north. The compass needle rotates in real-time to show the current direction, with the red end pointing north.
- Device with magnetometer sensor (smartphone/tablet)
- Expo Go app or development environment
- iOS/Android platform support