Skip to content

Latest commit

 

History

History
16 lines (11 loc) · 368 Bytes

File metadata and controls

16 lines (11 loc) · 368 Bytes

react-native-app-helpers/useStartSyncWhenTop

A React hook which starts sync when the current card is at the top of the stack.

Usage

import { useStartSyncWhenTop } from "react-native-app-helpers";
import { syncController } from "./your-services";

const ExampleScreen = ({ top }) => {
  useStartSyncWhenTop(syncController, top);

  return null;
};