# meliorence/react-native-snap-carousel architecture

> Architecture diagram of the GitHub repository meliorence/react-native-snap-carousel, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-09). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/meliorence/react-native-snap-carousel
- Repository: https://github.com/meliorence/react-native-snap-carousel

## Overview

This is a React Native carousel UI library. A consumer supplies data and an item renderer to Carousel; the component presents and snaps slides, while optional Pagination and ParallaxImage components provide navigation indicators and animated image treatment. README documents default, stack, tinder, custom-interpolation, large-list, and RTL capabilities. The sampled Carousel excerpt shows its animation-helper calls; unsampled rendering and integration details are not inferred beyond documented capabilities.

Main entry points: [`src/carousel/Carousel.js`](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/carousel/Carousel.js) (Carousel), [`src/index.js`](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/index.js) (Public exports), [`src/pagination/Pagination.js`](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/pagination/Pagination.js) (Pagination), [`src/pagination/PaginationDot.js`](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/pagination/PaginationDot.js) (Pagination dot)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_carousel["Carousel runtime"]
  node_api["Public exports<br/>[index.js]"]
  node_carousel_core["Carousel<br/>[Carousel.js]"]
end

subgraph group_presentation["Presentation features"]
  node_pagination["Pagination<br/>[Pagination.js]"]
  node_pagination_dot["Pagination dot<br/>[PaginationDot.js]"]
  node_pagination_style["Pagination styles"]
  node_parallax_image["Parallax image<br/>[ParallaxImage.js]"]
  node_parallax_style["Parallax styles"]
end

subgraph group_animation["Animation logic"]
  node_animation_helpers["Layout interpolations<br/>[animations.js]"]
end

node_consumer(("App developer"))
node_native_scroll["React Native scrolling"]

node_consumer -->|"imports"| node_api
node_api -->|"exports"| node_carousel_core
node_api -->|"exports"| node_pagination
node_api -->|"exports"| node_parallax_image
node_api -->|"exports"| node_animation_helpers
node_consumer -->|"supplies items"| node_carousel_core
node_carousel_core -->|"calls interpolations"| node_animation_helpers
node_carousel_core -.->|"renders scroll views"| node_native_scroll
node_pagination -->|"renders dots"| node_pagination_dot
node_pagination -->|"uses styles"| node_pagination_style
node_pagination_dot -->|"uses styles"| node_pagination_style
node_pagination_dot -->|"snaps via ref"| node_carousel_core
node_parallax_image -->|"uses styles"| node_parallax_style
node_parallax_image -->|"uses carousel props"| node_carousel_core

click node_api "https://github.com/meliorence/react-native-snap-carousel/blob/master/src/index.js"
click node_carousel_core "https://github.com/meliorence/react-native-snap-carousel/blob/master/src/carousel/Carousel.js"
click node_pagination "https://github.com/meliorence/react-native-snap-carousel/blob/master/src/pagination/Pagination.js"
click node_pagination_dot "https://github.com/meliorence/react-native-snap-carousel/blob/master/src/pagination/PaginationDot.js"
click node_pagination_style "https://github.com/meliorence/react-native-snap-carousel/blob/master/src/pagination/Pagination.style.js"
click node_parallax_image "https://github.com/meliorence/react-native-snap-carousel/blob/master/src/parallaximage/ParallaxImage.js"
click node_parallax_style "https://github.com/meliorence/react-native-snap-carousel/blob/master/src/parallaximage/ParallaxImage.style.js"
click node_animation_helpers "https://github.com/meliorence/react-native-snap-carousel/blob/master/src/utils/animations.js"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_api,node_carousel_core toneBlue
class node_pagination,node_pagination_dot,node_pagination_style,node_parallax_image,node_parallax_style toneAmber
class node_animation_helpers toneMint
class node_consumer,node_native_scroll toneIndigo
```

## Components

### Carousel runtime

- [Public exports](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/index.js): `src/index.js`
- [Carousel](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/carousel/Carousel.js): `src/carousel/Carousel.js`

### Presentation features

- [Pagination](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/pagination/Pagination.js): `src/pagination/Pagination.js`
- [Pagination dot](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/pagination/PaginationDot.js): `src/pagination/PaginationDot.js`
- [Pagination styles](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/pagination/Pagination.style.js): `src/pagination/Pagination.style.js`
- [Parallax image](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/parallaximage/ParallaxImage.js): `src/parallaximage/ParallaxImage.js`
- [Parallax styles](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/parallaximage/ParallaxImage.style.js): `src/parallaximage/ParallaxImage.style.js`

### Animation logic

- [Layout interpolations](https://github.com/meliorence/react-native-snap-carousel/blob/master/src/utils/animations.js): `src/utils/animations.js`

### Other components

- **App developer**
- **React Native scrolling**

## Connections

- App developer → Public exports: imports (evidence: `src/index.js`)
- Public exports → Carousel: exports (evidence: `src/index.js`)
- Public exports → Pagination: exports (evidence: `src/index.js`)
- Public exports → Parallax image: exports (evidence: `src/index.js`)
- Public exports → Layout interpolations: exports (evidence: `src/index.js`)
- App developer → Carousel: supplies items (evidence: `README.md`)
- Carousel → Layout interpolations: calls interpolations (evidence: `src/carousel/Carousel.js`)
- Carousel → React Native scrolling: renders scroll views
- Pagination → Pagination dot: renders dots (evidence: `src/pagination/Pagination.js`)
- Pagination → Pagination styles: uses styles (evidence: `src/pagination/Pagination.js`)
- Pagination dot → Pagination styles: uses styles (evidence: `src/pagination/PaginationDot.js`)
- Pagination dot → Carousel: snaps via ref (evidence: `src/pagination/PaginationDot.js`)
- Parallax image → Parallax styles: uses styles (evidence: `src/parallaximage/ParallaxImage.js`)
- Parallax image → Carousel: uses carousel props (evidence: `src/parallaximage/ParallaxImage.js`)
