Skip to main content
Version: Next

Variable: useForegroundService()

const useForegroundService: (config) => void = externalUseForegroundService

Defined in: packages/mobile-client/src/useForegroundService.ts:47

Hook for managing a foreground service on Android.

A hook for managing a foreground service on Android. Does nothing on other platforms. You can use this hook to keep your app running in the background. You're also required to run a foreground service when screen sharing.

Parameters

ParameterTypeDescription
configForegroundServiceConfigConfiguration options for the foreground service.

Returns

void