UNPKG

@trycourier/courier-react-native

Version:

Inbox, Push Notifications, and Preferences for React Native

29 lines 1.01 kB
import { BrandClient } from '..'; import { ClientModule } from './ClientModule'; import { InboxClient } from './InboxClient'; import { PreferenceClient } from './PreferenceClient'; import { TokenClient } from './TokenClient'; import { TrackingClient } from './TrackingClient'; export class CourierClient extends ClientModule { constructor(props) { const options = { userId: props.userId, showLogs: props.showLogs ?? __DEV__, jwt: props.jwt, clientKey: props.clientKey, connectionId: props.clientKey, tenantId: props.tenantId, apiUrls: props.apiUrls ? { ...props.apiUrls } : undefined }; super(options); this.options = options; this.tokens = new TokenClient(this.clientId); this.brands = new BrandClient(this.clientId); this.inbox = new InboxClient(this.clientId); this.preferences = new PreferenceClient(this.clientId); this.tracking = new TrackingClient(this.clientId); } } //# sourceMappingURL=CourierClient.js.map