Skip to content

Commit cabba5b

Browse files
authored
Update README.md
1 parent 1997877 commit cabba5b

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

README.md

+6-3
Original file line numberDiff line numberDiff line change
@@ -34,10 +34,13 @@ let pageControl = FlexiblePageControl(
3434
)
3535
view.addSubview(pageControl)
3636
````
37-
Update page
38-
````
39-
pageControl.selectedPage = page
4037

38+
update page
39+
40+
````
41+
func scrollViewDidScroll(_ scrollView: UIScrollView) {
42+
pageControl.setProgress(contentOffsetX: scrollView.contentOffset.x, pageWidth: scrollView.bounds.width)
43+
}
4144
````
4245

4346
# Licence

0 commit comments

Comments
 (0)