Camera-based inventory

Scan an item, confirm its identity, and record stock from a phone.

Customize the recipe

0/1500 characters

Prompt preview

# Camera-based inventory

Scan an item, confirm its identity, and record stock from a phone.

## Deliverable
A runnable scanner and manual-entry app with seeded inventory.

## Stack and visual direction
- Recommended starting stack: Expo, React Native and TypeScript. Use Expo Router for multiple screens and local persistence where needed.
- Minimalism: Use deliberate spacing, a compact palette and a clear typographic hierarchy. Retain the labels, feedback and affordances people need to act. Adapt this direction to native controls, navigation and platform accessibility conventions.

- Inspect the workspace first. Adapt to its stack when it contains a project, or use the recommended starting stack in a new workspace.

## Tools and setup · Universal
Use the receiving agent’s documented skill and tool mechanisms. Match setup to the agent and workspace you actually have.

Check available tools first. Propose documented project-level setup only when it materially helps and follow the host's permission prompts. If a tool or integration is unavailable, continue with the workflow below using existing tools, local fixtures or a manual check. Keep secrets in the intended configuration environment.

- [Expo Native UI](https://github.com/expo/skills/tree/main/plugins/expo/skills/expo-native-ui) (Skill) — Build native-feeling screens with platform-aware controls, safe areas and device checks.
  Fallback: Use native controls and the existing mobile framework's accessibility and safe-area APIs.
- [Expo Camera](https://github.com/expo/expo/tree/main/packages/expo-camera) (Repository) — Implement scanning or photo capture with explicit permission and fallback paths.
  [Official setup](https://docs.expo.dev/versions/latest/sdk/camera/).
- [Expo SQLite](https://github.com/expo/expo/tree/main/packages/expo-sqlite) (Repository) — Store structured entries locally and verify persistence after restart.
  [Official setup](https://docs.expo.dev/versions/latest/sdk/sqlite/).
- [React Native Accessibility](https://reactnative.dev/docs/accessibility) (Standard) — Check native semantic roles, accessible labels and assistive technology behavior.

## Workflow
1. Build scanning and manual lookup around a common item identifier. Pause or debounce scans, confirm item and quantity before saving, and keep a movement history.
2. Use the simplest implementation that delivers the stated outcome. Follow the user's project constraints and treat the starting stack as a default. Reuse existing work and ask for essential input only when it would change the result. Use realistic labeled sample data when real inputs are unavailable.
3. Run the applicable checks and report what actually passed along with any checks you could not run.

## Acceptance checks
- [ ] A repeated camera detection creates a single adjustment after confirmation.
- [ ] Manual lookup can complete the same task with camera access denied.
- [ ] Check platform accessibility labels and roles, screen-reader order, large text, touch targets, safe areas and software keyboard behavior.
- [ ] Verify real actions and persisted data where required. Exercise relevant loading, empty, invalid, pending, failure and success states. Provide a clear recovery path.
- [ ] Use a device or emulator when available. Exercise relevant permission, offline and restart states, and record which device scenarios you ran.

Recipe resources

Source, setup, and compatibility details.