Home » React Native ProgressBarAndroid

React Native ProgressBarAndroid

by Online Tutorials Library

React Native ProgressBarAndroid

The ProgressBarAndroid component of React Native is used to indicate the progress status of some activity or app loading something. ProgressBarAndroid component works only on Android platform. To use the progress bar in iOS platform, a ProgressViewIOS component is used.

Props of ProgressBarAndroid

animatingboolnoIt is used to show or hide the progress bar. Its default value is true to show, (false to hide).
colorcolornoIt sets the color of progress bar.
indeterminateindeterminateTypenoIt shows the intermediate progress status of progress bar. It can only be false if the styleAtte of progress bar is Horizontal.
progressnumbernoIt is a progress value between 0 and 1.
styleAttrenumnoIt sets the style of progress bar. There are various style of progress bar in React Native such as Horizontal, Normal (default), Small, Large, Inverse, SmallInverse, and LargeInverse.
testIDstringnoIt is used to locate this view in end-to-end tests.

React Native ProgressBarAndroid Example

In this example, we will implement horizontal ProgressBarAndroid and perform action on TouchableOpacity component. The progress status will display in Text component up to 3 digits only.


React Native ProgressBarAndroid React Native ProgressBarAndroid

You may also like