Skip to content

Commit 3204a96

Browse files
committed
Merge pull request #4 from jozan/patch-1
Update README to document Easing usage.
2 parents a031237 + 08a0749 commit 3204a96

File tree

1 file changed

+11
-27
lines changed

1 file changed

+11
-27
lines changed

README.md

Lines changed: 11 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -82,33 +82,17 @@ AppRegistry.registerComponent('rnsandbox', () => rnsandbox);
8282

8383
## Properties
8484

85-
#### `progress`
86-
87-
The progress value for the progress bar. Ranges from `0..1`.
88-
89-
#### `easing`
90-
91-
The easing function which is applied to the animation. Can be custom or one of the functions on the `ProgressBar.easingTypes` object.
92-
93-
#### `easingDuration`
94-
95-
The time taken to complete the animation.
96-
97-
#### `fillStyle`
98-
99-
The style for the progress bar fill.
100-
101-
#### `backgroundStyle`
102-
103-
The style for the progress bar's background.
104-
105-
#### `style`
106-
107-
The style for the entire component. This doesn't really differ from the `backgroundStyle` property. You must set `width` either here or in `backgroundStyle` in order to make sure the component works properly.
85+
| Prop | Description | Default |
86+
|---|---|---|
87+
|**`progress`**|The progress value for the progress bar. Ranges from `0..1`.|None|
88+
|**`easingDuration`**|The time taken to complete the animation in milliseconds.|`500`|
89+
|**`easing`**|Function from [`Easing`](https://github.com/facebook/react-native/blob/master/Libraries/Animation/Animated/Easing.js).|`Easing.inOut(Easing.ease)`|
90+
|**`fillStyle`**|The style for the progress bar fill.|None|
91+
|**`backgroundStyle `**|The style for the progress bar's background.|None|
92+
|**`style `**|The style for the entire component. This doesn't really differ from the `backgroundStyle` property. You must set width either here or in `backgroundStyle` in order to make sure the component works properly.|See [`ProgressBar.js`](https://github.com/lwansbrough/react-native-progress-bar/blob/master/ProgressBar.js)|
10893

10994

11095
## Component methods
111-
112-
#### `update(progress)`
113-
114-
The recommended way to update the progress of the progress bar is to use the `progress` property. If you prefer, you can use this `update` method to update the progress directly. To access this method, set the `ref` property on the `<ProgressBar>` and call `this.refs.progressBarName.update(0.3)`
96+
| Method | Description |
97+
|---|---|
98+
| **`update(progress)`** | The recommended way to update the progress of the progress bar is to use the `progress` property. If you prefer, you can use this `update` method to update the progress directly. To access this method, set the `ref` property on the `<ProgressBar>` and call `this.refs.progressBarName.update(0.3)` |

0 commit comments

Comments
 (0)