Skip to content

Latest commit

 

History

History
146 lines (82 loc) · 4.07 KB

analytics.configuration.md

File metadata and controls

146 lines (82 loc) · 4.07 KB

@segment/analytics-react-native > Configuration

Interface: Configuration

Hierarchy

Configuration

Index

Properties


Properties

<Optional> android

● android: undefined | object

Defined in analytics.ts:120

Android specific settings.


<Optional> debug

● debug: undefined | false | true

Defined in analytics.ts:38


<Optional> defaultProjectSettings

● defaultProjectSettings: undefined | object

Defined in analytics.ts:46

Default project settings to use, if Segment.com cannot be reached. An example configuration can be found here, using your write key: https://cdn-settings.segment.com/v1/projects/YOUR_WRITE_KEY/settings


<Optional> flushAt

● flushAt: undefined | number

Defined in analytics.ts:54

The number of queued events that the analytics client should flush at. Setting this to 1 will not queue any events and will use more battery.

20 by default.


<Optional> ios

● ios: undefined | object

Defined in analytics.ts:102

iOS specific settings.


<Optional> proxy

● proxy: undefined | object

Defined in analytics.ts:72

Whether the analytics client should send all requests through your own hosted proxy rather than directly to Segment. See: iOS: https://segment.com/docs/connections/sources/catalog/libraries/mobile/ios/#proxy-http-calls android: https://segment.com/docs/connections/sources/catalog/libraries/mobile/android/#proxy-http-calls

Ex. For a desired proxy through http://localhost:64000/segment the configuration would look like such { scheme: 'http', host: 'localhost', port: 64000, path: '/segment' }


<Optional> recordScreenViews

● recordScreenViews: undefined | false | true

Defined in analytics.ts:19

Whether the analytics client should automatically make a screen call when a view controller is added to a view hierarchy. Because the iOS underlying implementation uses method swizzling, we recommend initializing the analytics client as early as possible.

Disabled by default.


<Optional> trackAppLifecycleEvents

● trackAppLifecycleEvents: undefined | false | true

Defined in analytics.ts:26

Whether the analytics client should automatically track application lifecycle events, such as "Application Installed", "Application Updated" and "Application Opened".

Disabled by default.


<Optional> trackAttributionData

● trackAttributionData: undefined | false | true

Defined in analytics.ts:32

Whether the analytics client should automatically track attribution data from enabled providers using the mobile service.

Disabled by default.


<Optional> using

● using: Integration[]

Defined in analytics.ts:37

Register a set of integrations to be used with this Analytics instance.