Interface: TimestampTrigger

Defined in: packages/react-native/src/types/Trigger.ts:6

Interface for building a trigger with a timestamp.

View the Triggers documentation to learn more.

Properties

alarmManager?

optional alarmManager?: boolean | TimestampTriggerAlarmManager

Defined in: packages/react-native/src/types/Trigger.ts:56

Choose to schedule your trigger notification with Android's AlarmManager API.

By default, timestamp trigger notifications use AlarmManager on Android. Set this to false to opt out to WorkManager. RepeatFrequency.MONTHLY is not supported when this is false.

Platform

android

repeatFrequency?

optional repeatFrequency?: RepeatFrequency

Defined in: packages/react-native/src/types/Trigger.ts:28

The frequency at which the trigger repeats. If unset, the notification will only be displayed once.

For example: if set to RepeatFrequency.HOURLY, the notification will repeat every hour from the timestamp specified. if set to RepeatFrequency.DAILY, the notification will repeat every day from the timestamp specified. if set to RepeatFrequency.WEEKLY, the notification will repeat every week from the timestamp specified. if set to RepeatFrequency.MONTHLY, the notification will repeat every calendar month from the timestamp specified.

Yearly recurrence is not supported.

repeatInterval?

optional repeatInterval?: number

Defined in: packages/react-native/src/types/Trigger.ts:45

Multiplier applied to repeatFrequency for timestamp triggers.

For example, repeatFrequency: RepeatFrequency.DAILY with repeatInterval: 2 repeats every 2 days. RepeatFrequency.WEEKLY with repeatInterval: 2 repeats every 2 weeks, and RepeatFrequency.MONTHLY with repeatInterval: 3 repeats every 3 months.

Valid only when repeatFrequency is set to a repeating value. It is not valid without repeatFrequency or with RepeatFrequency.NONE. Must be a positive integer.

Defaults to 1 when repeatFrequency is set.

timestamp

timestamp: number

Defined in: packages/react-native/src/types/Trigger.ts:14

The timestamp when the notification should first be shown, in milliseconds since 1970.

type

type: TIMESTAMP

Defined in: packages/react-native/src/types/Trigger.ts:10

Constant enum value used to identify the trigger type.