This repository demonstrates automatic video recording with expo-camera.
- Node.js 16 (
.nvmrcprovided) - Expo CLI (
npm install -g expo-cli) - Xcode / Android Studio if you intend to run on iOS or Android emulators/devices
# clone repo then
npm install# iOS simulator
npm run ios
# Android emulator/device
npm run android
# Web (uses your browser camera)
npm run web- On mount we request camera permissions.
- When the camera becomes ready the app automatically starts recording using
recordAsync(). - After 3 seconds it stops and logs the resulting video object in the dev console.
Feel free to adjust recording duration or add UI controls in App.tsx.
├── App.tsx # main screen with CameraView logic
├── package.json
├── android/ # native Android project (generated by Expo)
├── ios/ # native iOS project (generated by Expo)
└── README.md # this file
- Permissions denied – make sure the simulator/device/browser has camera access.
- Camera not available on web – some browsers block insecure origins; use HTTPS or
expo-preview.
MIT