@amrshbib/react-native-background-tasks
Version: 
React Native background service package for continuous background tasks with sticky notifications
16 lines (13 loc) • 415 B
TypeScript
export interface BackgroundServiceOptions {
  taskId: string;
  title: string;
  description: string;
  intervalMs?: number;
}
export interface BackgroundService {
  start(taskFunction: () => void, options: BackgroundServiceOptions): Promise<string>;
  stop(taskId: string): Promise<string>;
  isRunning(taskId: string): Promise<boolean>;
}
declare const Background: BackgroundService;
export default Background;