Skip to content

Commit c9fa640

Browse files
committed
added react native 2.0 [netlify-build]
1 parent caf490e commit c9fa640

File tree

5 files changed

+43
-4
lines changed

5 files changed

+43
-4
lines changed

src/connections/destinations/destination-filters.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ rewrite: true
66
> info ""
77
> Destination filters are only available to Business Tier customers.
88
>
9-
> Destination filters for mobile device-mode destinations are in beta and only supports [Swift](/docs/connections/sources/catalog/libraries/mobile/swift-ios#destination-filters) and [Kotlin](/docs/connections/sources/catalog/libraries/mobile/kotlin-android/#destination-filters) libraries.
9+
> Destination filters for mobile device-mode destinations are in beta and only supports [Swift](/docs/connections/sources/catalog/libraries/mobile/swift-ios#destination-filters), [Kotlin](/docs/connections/sources/catalog/libraries/mobile/kotlin-android/#destination-filters) and [React Native 2.0](/docs/connections/sources/catalog/libraries/mobile/react-native/#destination-filters) libraries.
1010
1111
Use destination filters to prevent certain data from flowing into a destination. You can conditionally filter out event properties, traits, and fields, or even filter out the event itself.
1212

src/connections/sources/catalog/libraries/mobile/kotlin-android/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,7 @@ The example projects contain sample [plugins](https://github.com/segmentio/analy
347347
> info ""
348348
> Destination filters are only available to Business Tier customers.
349349
>
350-
> Destination filters on mobile device-mode destinations are in beta and only supports Analytics-Kotlin and [Analytics-Swift](/docs/connections/sources/catalog/libraries/mobile/swift-ios/).
350+
> Destination filters on mobile device-mode destinations are in beta and only supports Analytics-Kotlin, [Analytics-Swift](/docs/connections/sources/catalog/libraries/mobile/swift-ios/), and [Analytics-React-Native 2.0](/docs/connections/sources/catalog/libraries/mobile/react-native/).
351351
352352
Use Analytics Kotlin (Android) to configure [destination filters](docs/connections/destinations/destination-filters/) on your mobile device-mode destinations.
353353

src/connections/sources/catalog/libraries/mobile/react-native/index.md

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -491,6 +491,45 @@ These are the example plugins you can use and alter to meet your tracking needs:
491491
| Firebase | `@segment/analytics-react-native-plugin-consent-firebase` |
492492
| IDFA | `@segment/analytics-react-native-plugin-idfa` |
493493
494+
## Destination Filters
495+
> info ""
496+
> Destination filters are only available to Business Tier customers.
497+
>
498+
> Destination filters on mobile device-mode destinations are in beta and only supports Analytics-React-Native 2.0, [Analytics-Swift](/docs/connections/sources/catalog/libraries/mobile/swift-ios/) and [Analytics-Kotlin](/docs/connections/sources/catalog/libraries/mobile/kotlin-android/).
499+
500+
Use Analytics-React-Native 2.0 to set up [destination filters](docs/connections/destinations/destination-filters/) on your mobile device-mode destinations.
501+
502+
> warning ""
503+
> You must use React Native version 2.9 or higher to implement destination filters.
504+
>
505+
> Keep [these limitations](/docs/connections/destinations/destination-filters/#limitations) in mind when using destination filters.
506+
507+
To get started with destination filters on mobile device-mode destinations using React Native 2.0:
508+
1. Download and install the `@segment/analytics-react-native-plugin-destination-filters` package as a dependency in your project.
509+
* Using NPM:
510+
```npm
511+
npm install --save @segment/analytics-react-native-plugin-destination-filters
512+
```
513+
* Using Yarn:
514+
```yarn
515+
yarn add @segment/analytics-react-native-plugin-destination-filters
516+
```
517+
2. Follow the instructions for [adding plugins](/docs/connections/sources/catalog/libraries/mobile/react-native/#adding-plugins) on the main Analytics client.
518+
3. Add `DestinationFiltersPlugin` after you create your Segment client.
519+
520+
```kotlin
521+
import { createClient } from '@segment/analytics-react-native';
522+
523+
import { DestinationFiltersPlugin } from '@segment/analytics-react-native-plugin-destination-filters';
524+
525+
const segmentClient = createClient({
526+
writeKey: 'SEGMENT_KEY'
527+
});
528+
529+
segmentClient.add({ plugin: new DestinationFiltersPlugin() });
530+
segment.add({ plugin: new FirebasePlugin() })
531+
```
532+
494533
## Supported Destinations
495534
Segment supports a large number of [Cloud-mode](/docs/connections/destinations/#connection-modes) destinations. Segment also supports the below destinations for Analytics React Native 2.0 in device-mode, with more to follow:
496535
- [Adjust](https://www.npmjs.com/package/@segment/analytics-react-native-plugin-adjust){:target="_blank"}

src/connections/sources/catalog/libraries/mobile/swift-ios/index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ Though you can add plugins anywhere in your code, it's best to implement your pl
338338
> info ""
339339
> Destination filters are only available to Business Tier customers.
340340
>
341-
> Destination filters on mobile device-mode destinations are in beta and only supports Analytics-Swift and [Analytics-Kotlin](/docs/connections/sources/catalog/libraries/mobile/kotlin-android/).
341+
> Destination filters on mobile device-mode destinations are in beta and only supports Analytics-Swift, [Analytics-Kotlin](/docs/connections/sources/catalog/libraries/mobile/kotlin-android/), and [Analytics-React-Native 2.0](/docs/connections/sources/catalog/libraries/mobile/react-native/).
342342

343343
Use Analytics Swift to set up [destination filters](docs/connections/destinations/destination-filters/) on your mobile device-mode destinations.
344344

src/guides/filtering-data.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,7 @@ Your data is sent to your warehouse (if you have one) and into the Segment backe
5050
> info ""
5151
> Destination filters are only available in workspaces that are on a Business Tier plan.
5252
>
53-
> Destination filters for mobile device-mode destinations are in beta and only supports [Swift](/docs/connections/sources/catalog/libraries/mobile/swift-ios#destination-filters) and [Kotlin](/docs/connections/sources/catalog/libraries/mobile/kotlin-android/#destination-filters) libraries.
53+
> Destination filters for mobile device-mode destinations are in beta and only supports [Swift](/docs/connections/sources/catalog/libraries/mobile/swift-ios#destination-filters), [Kotlin (Android)](/docs/connections/sources/catalog/libraries/mobile/kotlin-android/#destination-filters), and [React Native 2.0](/docs/connections/sources/catalog/libraries/mobile/react-native/#destination-filters) libraries.
5454
5555
> warning ""
5656
> Keep [these limitations](/docs/connections/destinations/destination-filters/#limitations) in mind when using destination filters.

0 commit comments

Comments
 (0)