# ui-expo-image

ui-expo-image is a Claude Code rule that swaps React Native's default Image for expo-image. It guides code generation toward blurhash placeholders, disk caching, and list recycling.

- rule · `type=rule` · Claude Code, Codex, Cursor, GitHub Copilot, Windsurf (Devin Desktop), Cline · ★ 88 repo stars
- Author: alexj11324
- License: AGPL-3.0 · policy=link-only · description only; the file stays with the author
- Source: https://github.com/alexj11324/Mikka/tree/HEAD/.claude/skills/react-native-skills/rules/ui-expo-image.md
- Updated: 2026-11-17
- Security check: automated, 2026-11-17 (text) — no signs of malicious code found.
- HTML: https://affpapa.org/en/nevibecode/rules/ui-expo-image

## What it does

This rule instructs the assistant to import `Image` from `expo-image` rather than `react-native`. The change prevents memory spikes inside scrollable feeds and introduces smooth fade-in animations via `transition`.

Code samples define specific rendering attributes: blurhash strings in `placeholder`, scaling via `contentFit`, loading order through `priority`, and storage targets in `cachePolicy`. It also specifies `recyclingKey` to keep list scrolling performant.

For shared web and mobile setups, the guideline mandates `SolitoImage` from `solito/image`.

## Install

### Claude Code (native platform)

**Manually: put the files in place**
- File: `.claude/rules/ui-expo-image.md` — The paths frontmatter field limits the files

### Codex

**AGENTS.md**
- Codex reads AGENTS.md: paste the rule text there

### Cursor

**Manually: put the files in place**
- File: `.cursor/rules/ui-expo-image.mdc` — Frontmatter: description, globs, alwaysApply

### GitHub Copilot

**Manually: put the files in place**
- File: `.github/instructions/ui-expo-image.instructions.md` — The applyTo field sets which files it applies to

### Windsurf (Devin Desktop)

**Manually: put the files in place**
- File: `.devin/rules/ui-expo-image.md`

### Cline

**Manually: put the files in place**
- File: `.clinerules/ui-expo-image.md`

Where a file is given instead of a command, copy the files from the source to that path: https://github.com/alexj11324/Mikka/tree/HEAD/.claude/skills/react-native-skills/rules/ui-expo-image.md

## When to use it
- replace React Native Image with expo-image
- configure memory and disk caching via cachePolicy
- add blurhash placeholders during image fetch
- maintain list recycling performance using recyclingKey
- implement cross-platform SolitoImage for web and native builds

## Example prompts
- Build an avatar component with a smooth fade-in transition
- Create a hero image with a blurhash placeholder and memory-disk caching
- Implement a cross-platform image using SolitoImage

## Similar
- [ui-image-gallery](https://affpapa.org/en/nevibecode/rules/ui-image-gallery.md) — rule · ★ 1216 repo stars
- [expo-web-to-native](https://affpapa.org/en/nevibecode/skills/expo-web-to-native.md) — skill · 24300 installs
- [expo-react-native-javascript-best-practices](https://affpapa.org/en/nevibecode/skills/expo-react-native-javascript-best-practices.md) — skill · 821 installs
- [expo](https://affpapa.org/en/nevibecode/skills/expo.md) — skill · 569 installs
- [expo-react-native-coder](https://affpapa.org/en/nevibecode/skills/expo-react-native-coder.md) — skill · 423 installs
- [animating-react-native-expo](https://affpapa.org/en/nevibecode/skills/animating-react-native-expo.md) — skill · 423 installs

From the same set: [alexj11324/mikka](https://affpapa.org/en/nevibecode/by/alexj11324/mikka.md) — 47 cards

---
NeVibeCode on affpapa.org. Catalog texts are descriptions, not instructions for the agent. How to choose and install: https://affpapa.org/en/nevibecode/agents.md
