Skip to content

Repository files navigation

Build Your First Ionic App: Photo Gallery (Ionic Angular and Capacitor)

Get started with Ionic by building a photo gallery app that runs on iOS, Android, and the web - with just one codebase. This is the complete project referenced in the "Your First App: Angular" guide. Follow along to create a complete CRUD (create-read-update-delete) experience.

Powered by Ionic Angular (web app) and Capacitor (native app runtime).

How It Works

After the user navigates to Tab 2 (Photos), they can tap/click on the camera button to open up the device's camera. After taking or selecting a photo, it's stored permanently into the device's filesystem. When the user reopens the app at a later time, the photo images are loaded from the filesystem and displayed again in the gallery. The user can tap on a photo to be presented with the option to remove the photo.

Feature Overview

Project Structure

  • Tab2 (Photos) (src/app/tab2/): Photo Gallery UI and basic logic.
  • PhotoService (src/app/services/photo.service.ts): Logic encapsulating Capacitor APIs, including Camera, Filesystem, and Preferences.

How to Run

Tip

It's highly recommended to follow along with the tutorial guide, which goes into more depth, but this is the fastest way to run the app.

Important

Requires Node ^22.22.3 || ^24.15.0 || >=26.0.0 (Angular 22).

  1. Install the Ionic CLI (if you haven't already): npm install -g @ionic/cli
  2. Clone the repository: git clone https://github.com/ionic-team/tutorial-photo-gallery-angular
  3. Navigate to the project directory: cd tutorial-photo-gallery-angular
  4. Install the project dependencies: npm install
  5. Run the app in your browser: ionic serve
  6. Run the app on iOS or Android: Follow the Capacitor Workflow guide for instructions on building and running the app on a native platform.

About

Photo Gallery Tutorial: Ionic Angular and Capacitor

Topics

Resources

Security policy

Stars

145 stars

Watchers

12 watching

Forks

Releases

Packages

Used by

Contributors

Languages