Installations
npm install react-native-app-intro-slider
Developer Guide
Typescript
Yes
Module System
CommonJS
Node Version
12.16.1
NPM Version
6.13.4
Score
94.4
Supply Chain
99.5
Quality
76
Maintenance
100
Vulnerability
100
License
Releases
Contributors
Unable to fetch Contributors
Languages
TypeScript (97.64%)
JavaScript (2.36%)
Love this project? Help keep it running — sponsor us today! 🚀
Developer
jacse
Download Statistics
Total Downloads
3,605,630
Last Day
584
Last Week
15,472
Last Month
61,601
Last Year
733,838
GitHub Statistics
MIT License
1,672 Stars
106 Commits
330 Forks
19 Watchers
2 Branches
20 Contributors
Updated on Feb 15, 2025
Package Meta Information
Latest Version
4.0.4
Package Id
react-native-app-intro-slider@4.0.4
Size
7.31 kB
NPM Version
6.13.4
Node Version
12.16.1
Published on
May 26, 2020
Total Downloads
Cumulative downloads
Total Downloads
3,605,630
Last Day
-29.6%
584
Compared to previous day
Last Week
-8.7%
15,472
Compared to previous week
Last Month
34.4%
61,601
Compared to previous month
Last Year
-5.8%
733,838
Compared to previous year
Daily Downloads
Weekly Downloads
Monthly Downloads
Yearly Downloads
react-native-app-intro-slider
An easy-to-use yet very configurable app introduction slider/swiper based on FlatList that supports RTL.
1yarn add react-native-app-intro-slider
Usage
Simple examples
Basic | showSkipButton | bottomButton and showSkipButton |
---|---|---|
![]() | ![]() | ![]() |
The component is based on FlatList so usage is very similar. Pass a data-array to AppIntroSlider along with a renderItem
-function:
1import React from 'react'; 2import { StyleSheet } from 'react-native'; 3import AppIntroSlider from 'react-native-app-intro-slider'; 4 5const slides = [ 6 { 7 key: 1, 8 title: 'Title 1', 9 text: 'Description.\nSay something cool', 10 image: require('./assets/1.jpg'), 11 backgroundColor: '#59b2ab', 12 }, 13 { 14 key: 2, 15 title: 'Title 2', 16 text: 'Other cool stuff', 17 image: require('./assets/2.jpg'), 18 backgroundColor: '#febe29', 19 }, 20 { 21 key: 3, 22 title: 'Rocket guy', 23 text: 'I\'m already out of descriptions\n\nLorem ipsum bla bla bla', 24 image: require('./assets/3.jpg'), 25 backgroundColor: '#22bcb5', 26 } 27]; 28 29export default class App extends React.Component { 30 this.state = { 31 showRealApp: false 32 } 33 _renderItem = ({ item }) => { 34 return ( 35 <View style={styles.slide}> 36 <Text style={styles.title}>{item.title}</Text> 37 <Image source={item.image} /> 38 <Text style={styles.text}>{item.text}</Text> 39 </View> 40 ); 41 } 42 _onDone = () => { 43 // User finished the introduction. Show real app through 44 // navigation or simply by controlling state 45 this.setState({ showRealApp: true }); 46 } 47 render() { 48 if (this.state.showRealApp) { 49 return <App />; 50 } else { 51 return <AppIntroSlider renderItem={this._renderItem} data={slides} onDone={this._onDone}/>; 52 } 53 } 54}
Configuring buttons
1import React from 'react'; 2import Icon from 'react-native-vector-icons/Ionicons'; 3import { StyleSheet, View } from 'react-native'; 4import AppIntroSlider from 'react-native-app-intro-slider'; 5 6const styles = StyleSheet.create({ 7 buttonCircle: { 8 width: 40, 9 height: 40, 10 backgroundColor: 'rgba(0, 0, 0, .2)', 11 borderRadius: 20, 12 justifyContent: 'center', 13 alignItems: 'center', 14 }, 15 //[...] 16}); 17 18// slides = [...] 19 20export default class App extends React.Component { 21 _renderItem = ({ item }) => { 22 return ( 23 <View style={styles.slide}> 24 <Text style={styles.title}>{item.title}</Text> 25 <Image source={item.image} /> 26 <Text style={styles.text}>{item.text}</Text> 27 </View> 28 ); 29 } 30 _renderNextButton = () => { 31 return ( 32 <View style={styles.buttonCircle}> 33 <Ion 34 name="md-arrow-round-forward" 35 color="rgba(255, 255, 255, .9)" 36 size={24} 37 /> 38 </View> 39 ); 40 }; 41 _renderDoneButton = () => { 42 return ( 43 <View style={styles.buttonCircle}> 44 <Ion 45 name="md-checkmark" 46 color="rgba(255, 255, 255, .9)" 47 size={24} 48 /> 49 </View> 50 ); 51 }; 52 render() { 53 return ( 54 <AppIntroSlider 55 data={slides} 56 renderDoneButton={this._renderDoneButton} 57 renderNextButton={this._renderNextButton} 58 /> 59 ); 60 } 61}
Here a custom renderItem
is supplied and the bottomButton
-props has been set to true
. Notice how the setup of slides
has been configured to support icons and gradient backgrounds.
Props and methods
The component extends FlatList
so all FlatList-props are valid.
Props
Name | Type | Default | Description |
---|---|---|---|
data | object | None, required | An array of objects (they should either contain a unique key -prop or you should pass a keyExtractor -function to the component) |
renderItem | function | None, required | FlatList's renderItem. Receives ({item, index, dimensions}) where dimensions contains height and width of the slides |
onSlideChange | function | void | Called when user goes changes slide (by swiping or pressing next/prev). Function called with arguments (index: number, lastIndex: number) |
renderPagination | function | Function to render a custom pagination/button component on top of slides. Receives the index of the currently active slide | |
onDone | function | void | Called when user ends the introduction by pressing the done button |
onSkip | function | Scrolls to the end | Called when user presses the skip button |
bottomButton | boolean | false | Enable to show a full-width button under pagination |
dotStyle | style | {backgroundColor: 'rgba(0, 0, 0, .2)'} | Style of inactive pagination dots |
dotClickEnabled | boolean | true | Whether users can navigate using the pagination dots |
activeDotStyle | style | {backgroundColor: 'rgba(255, 255, 255, .9)'} | Style of active pagination dot |
skipLabel | string | Skip | Custom label for Skip button |
doneLabel | string | Done | Custom label for Done button |
nextLabel | string | Next | Custom label for Next button |
prevLabel | string | Back | Custom label for Prev button |
showSkipButton | boolean | false | Enable to show a skip button to the left of pagination dots. When bottomButton == true the skip button is a small text under the full-width next button |
showPrevButton | boolean | false | Enable to show a previous button. If showSkipButton is true, the skip button will be displayed on the first page and prev button on subsequent one |
showNextButton | boolean | true | Disable to hide the next button |
showDoneButton | boolean | true | Disable to hide the done button |
renderNextButton | function | renders a Text-component | Use to supply your own next button. Has no effect if using renderPagination . |
renderPrevButton | function | renders a Text-component | Use to supply your own prev button . Has no effect if using renderPagination |
renderDoneButton | function | renders a Text-component | Use to supply your own done button. Has no effect if using renderPagination |
renderSkipButton | function | renders a Text-component | Use to supply your own skip button. Has no effect if using renderPagination |
Methods
Method Name | Arguments | Description |
---|---|---|
goToSlide | number | Change to slide with specified index |
getListRef | none | Returns the Flat List ref |
Examples

No vulnerabilities found.
Reason
no binaries found in the repo
Reason
license file detected
Details
- Info: project has a license file: LICENSE:0
- Info: FSF or OSI recognized license: MIT License: LICENSE:0
Reason
Found 8/28 approved changesets -- score normalized to 2
Reason
0 commit(s) and 0 issue activity found in the last 90 days -- score normalized to 0
Reason
no effort to earn an OpenSSF best practices badge detected
Reason
security policy file not detected
Details
- Warn: no security policy file detected
- Warn: no security file to analyze
- Warn: no security file to analyze
- Warn: no security file to analyze
Reason
project is not fuzzed
Details
- Warn: no fuzzer integrations found
Reason
branch protection not enabled on development/release branches
Details
- Warn: branch protection not enabled for branch 'master'
Reason
SAST tool is not run on all commits -- score normalized to 0
Details
- Warn: 0 commits out of 11 are checked with a SAST tool
Reason
54 existing vulnerabilities detected
Details
- Warn: Project is vulnerable to: GHSA-67hx-6x53-jw92
- Warn: Project is vulnerable to: GHSA-v88g-cgmw-v5xw
- Warn: Project is vulnerable to: GHSA-93q8-gq69-wqmw
- Warn: Project is vulnerable to: GHSA-fwr7-v2mv-hh25
- Warn: Project is vulnerable to: GHSA-grv7-fg5c-xmjg
- Warn: Project is vulnerable to: GHSA-3xgq-45jj-v275
- Warn: Project is vulnerable to: GHSA-gxpj-cx7g-858c
- Warn: Project is vulnerable to: GHSA-w573-4hg7-7wgq
- Warn: Project is vulnerable to: GHSA-ww39-953v-wcq6
- Warn: Project is vulnerable to: GHSA-f5x2-xv93-4p23
- Warn: Project is vulnerable to: GHSA-gmpm-xp43-f7g6
- Warn: Project is vulnerable to: GHSA-pf27-929j-9pmm
- Warn: Project is vulnerable to: GHSA-327c-qx3v-h673
- Warn: Project is vulnerable to: GHSA-x4cf-6jr3-3qvp
- Warn: Project is vulnerable to: GHSA-mph8-6787-r8hw
- Warn: Project is vulnerable to: GHSA-7mhc-prgv-r3q4
- Warn: Project is vulnerable to: GHSA-43f8-2h32-f4cj
- Warn: Project is vulnerable to: GHSA-896r-f27r-55mw
- Warn: Project is vulnerable to: GHSA-9c47-m6qq-7p4h
- Warn: Project is vulnerable to: GHSA-p6mc-m468-83gw
- Warn: Project is vulnerable to: GHSA-29mw-wpgm-hmr9
- Warn: Project is vulnerable to: GHSA-35jh-r3h4-6jhm
- Warn: Project is vulnerable to: GHSA-v8v8-6859-qxm4
- Warn: Project is vulnerable to: GHSA-952p-6rrq-rcjv
- Warn: Project is vulnerable to: GHSA-f8q6-p94x-37v3
- Warn: Project is vulnerable to: GHSA-xvch-5gv4-984h
- Warn: Project is vulnerable to: GHSA-r683-j2x4-v87g
- Warn: Project is vulnerable to: GHSA-w7rc-rwvf-8q5r
- Warn: Project is vulnerable to: GHSA-5fw9-fq32-wv5p
- Warn: Project is vulnerable to: GHSA-hj48-42vr-x3v9
- Warn: Project is vulnerable to: GHSA-4cpg-3vgw-4877
- Warn: Project is vulnerable to: GHSA-hrpp-h998-j3pp
- Warn: Project is vulnerable to: GHSA-rxrc-rgv4-jpvx
- Warn: Project is vulnerable to: GHSA-7f53-fmmv-mfjv
- Warn: Project is vulnerable to: GHSA-p8p7-x288-28g6
- Warn: Project is vulnerable to: GHSA-c2qf-rxjj-qqgw
- Warn: Project is vulnerable to: GHSA-m6fv-jmcg-4jfg
- Warn: Project is vulnerable to: GHSA-cm22-4g7w-348p
- Warn: Project is vulnerable to: GHSA-g4rg-993r-mgx7
- Warn: Project is vulnerable to: GHSA-gff7-g5r8-mg8m
- Warn: Project is vulnerable to: GHSA-jgrx-mgxx-jf9v
- Warn: Project is vulnerable to: GHSA-72xf-g2v4-qvf3
- Warn: Project is vulnerable to: GHSA-662x-fhqg-9p8v
- Warn: Project is vulnerable to: GHSA-394c-5j6w-4xmx
- Warn: Project is vulnerable to: GHSA-78cj-fxph-m83p
- Warn: Project is vulnerable to: GHSA-fhg7-m89q-25r3
- Warn: Project is vulnerable to: GHSA-j8xg-fqg3-53r7
- Warn: Project is vulnerable to: GHSA-6fc8-4gx4-v693
- Warn: Project is vulnerable to: GHSA-3h5v-q93c-6h6q
- Warn: Project is vulnerable to: GHSA-h6q6-9hqw-rwfv
- Warn: Project is vulnerable to: GHSA-5fg8-2547-mr8q
- Warn: Project is vulnerable to: GHSA-crh6-fp67-6883
- Warn: Project is vulnerable to: GHSA-c4w7-xm78-47vh
- Warn: Project is vulnerable to: GHSA-p9pc-299p-vxgp
Score
2
/10
Last Scanned on 2025-02-10
The Open Source Security Foundation is a cross-industry collaboration to improve the security of open source software (OSS). The Scorecard provides security health metrics for open source projects.
Learn MoreOther packages similar to react-native-app-intro-slider
react-native-slider-intro
A simple and full customizable React Native package which implements a unique slider.
@unbogify/react-native-app-intro-slider
Simple and configurable app introduction slider for react native
react-native-app-intro-slider-mod
Simple and configurable app introduction slider for react native
@types/react-native-app-intro-slider
Stub TypeScript definitions entry for react-native-app-intro-slider, which provides its own types definitions