This is an Expo Router project to demonstrate choosing media from the device and uploading it to a server.
- Pick an image or video with
ImagePicker
. - Upload the media with built-in
fetch
andFormData
APIs. - Use Expo Router API routes to handle the upload on the server. This can be deployed to hosting providers by following the API routes deployment guide.
- Save the file using a pseudo-database with Node.js
fs
andpath
modules. In production, you'd use a real database like MongoDB or PostgreSQL.
-
Install dependencies
npm install
-
Start the app
npx expo start
You can run the app on iOS, Android, and the web:
- development build
- Android emulator
- iOS simulator
- Expo Go, a limited sandbox for trying out app development with Expo
You can start developing by editing the files inside the app directory. This project uses file-based routing.
To learn more about developing your project with Expo, look at the following resources:
- Expo documentation: Learn fundamentals, or go into advanced topics with our guides.
- Learn Expo tutorial: Follow a step-by-step tutorial where you'll create a project that runs on Android, iOS, and the web.
Join our community of developers creating universal apps.
- Expo on GitHub: View our open source platform and contribute.
- Discord community: Chat with Expo users and ask questions.