ReScript bindings for @react-native-community/viewpager.
npm install @reason-react-native/viewpager@reason-react-native/viewpager


ReScript / Reason bindings for@react-native-community/viewpager.
Exposed as ReactNativeViewPager module.
@reason-react-native/viewpager X.y.\* means it's compatible with@react-native-community/viewpager X.y.\*
When@react-native-community/viewpager
is properly installed & configured by following their installation instructions,
you can install the bindings:
``console`
npm install @reason-react-native/viewpageror
yarn add @reason-react-native/viewpager
@reason-react-native/viewpager should be added to bs-dependencies in yourbsconfig.json:
`diff`
{
//...
"bs-dependencies": [
"reason-react",
"reason-react-native",
// ...
+ "@reason-react-native/viewpager"
],
//...
}
`reasoncurl}
[@react.component]
let app = () =>
pageMargin=13
transitionStyle={
showPageIndicator=true
>
;
``
#### ReactNativeViewPager props
`reasonnone | [@bs.as "on-drag"]
~ref: ref=?,
~initialPage: int=?,
~scrollEnabled: bool=?,
~onPageScroll: PageScrollEvent.t => unit=?,
~onPageSelected: PageSelectedEvent.t => unit=?,
~onPageScrollStateChanged: PageScrollStateChangedEvent.t => unit=?,
~keyboardDismissMode: [@bs.string] [ | onDrag]=?,horizontal |
~pageMargin: int=?,
~onMoveShouldSetResponderCapture: ReactNative.Event.pressEvent => bool=?,
~style: ReactNative.Style.t=?,
~children: React.element=?,
~orientation: [@bs.string] [ | vertical]=?,scroll |
~transitionStyle: [@bs.string] [ | curl]=?,`
~showPageIndicator: bool=?
#### ReactNativeViewPager.setPage
`reason`
setPage: (T.t, int) => unit = "setPage";
#### ReactNativeViewPager.setPage
`reason``
setPageWithoutAnimation: (T.t, int) => unit =
"setPageWithoutAnimation";
---
Check the changelog for more informations about recent
releases.
---
Read the
contribution guidelines
before contributing.
We want this community to be friendly and respectful to each other. Please read
our full code of conduct
so that you can understand what actions will and will not be tolerated.