0.1.2 • Published 2 years ago

react-native-view-visibility v0.1.2

Weekly downloads
-
License
MIT
Repository
github
Last release
2 years ago

react-native-view-visibility

react-native-view-visibility

Installation

npm install react-native-view-visibility

Usage

import { ViewVisibility } from "react-native-view-visibility";

// ...

<ViewVisibility idBanner={'12345'}>
  // ...
</ViewVisibility>

AppNexusBanner props:

NameDescriptionRequiredTypeExample
idBannerThe placement ID identifies your banner in the system.YESString"1234567"
percentVisibilityThe offset when the banner is considered visible (percentage of the entire banner view holder). Default: 50NoNumber50
horizontalIf used in horizontal scrolling, you need to install trueNoBooleanfalse
onAdVisibleChangeA callback triggered when the visibility of the banner has been changed. Returns a visibility type (0 - if banner is not visible, 1 - if banner is partially visible, 2 - If banner is percent visible, 3 - If banner is fully visibleNoFunction(visibilityType: number) => console.log("The visibility has changed", visibilityType)

Contributing

See the contributing guide to learn how to contribute to the repository and the development workflow.

License

MIT