Skip to main content
Glama
view-pager.md1.29 kB
--- title: ViewPager description: A component library that provides a carousel-like view to swipe through pages of content. sourceCodeUrl: https://github.com/callstack/react-native-pager-view packageName: react-native-pager-view platforms: ["android", "ios"] --- > **info** This library is listed in the Expo SDK reference because it is included in [Expo Go](https://expo.dev/go). You may use any library of your choice with [development builds](/develop/development-builds/introduction/). `react-native-pager-view` exposes a component that provides the layout and gestures to scroll between pages of content, like a carousel. ## Installation ## Usage See full documentation at [callstack/react-native-pager-view](https://github.com/callstack/react-native-pager-view). ## Example ```jsx App.js return ( <PagerView style={styles.container} initialPage={0}> <View style={styles.page} key="1"> <Text>First page</Text> <Text>Swipe ➡️</Text> <Text>Second page</Text> <Text>Third page</Text> </PagerView> </View> ); } const styles = StyleSheet.create({ container: { flex: 1, }, page: { justifyContent: 'center', alignItems: 'center', }, }); ```

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/jaksm/expo-docs-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server