Skip to content

9.0.0 #8

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 30 commits into from
Jun 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
1310845
android: bump batch sdk to 2.0
arnaud-roland May 16, 2024
2f44baa
android: update how to start batch
arnaud-roland May 16, 2024
0558a8d
android: update how to get push token
arnaud-roland May 16, 2024
398bcc9
bridge: remove trackTransaction API
arnaud-roland May 16, 2024
81dc271
android: bump android min sdk version to 21
arnaud-roland May 17, 2024
a76812e
android: bump AGP to 8.2.2
arnaud-roland May 17, 2024
7ca6ef9
android: make plugin compile on batch v2
arnaud-roland May 17, 2024
2cce40d
android: add profile module + rework editor
arnaud-roland May 22, 2024
d779e87
android: add rich event compatibility
arnaud-roland May 23, 2024
9cf117f
ios: bump batch to 2.0
arnaud-roland May 24, 2024
3f1a554
ios: bump min ios to 13
arnaud-roland May 24, 2024
b9bbc49
ios: compat batch sdk 2.0
arnaud-roland May 24, 2024
503e904
bridge: add profile identify api
arnaud-roland May 27, 2024
3e2fc50
bridge: add isOptedOut api
arnaud-roland May 27, 2024
1285a5a
bridge: add updateDataCollection api
arnaud-roland May 28, 2024
0af4e3c
bridge: add default profile migrations
arnaud-roland May 29, 2024
160679d
bridge: add clear install data api
arnaud-roland May 29, 2024
3bb5af5
bridge: rename internal bridge methods
arnaud-roland May 29, 2024
4873e0e
event: remove js side event attributes validations since its already …
arnaud-roland May 29, 2024
6228fc2
expo: add expo configuration support for batch 2.0
arnaud-roland May 30, 2024
e4ca119
ios: add default chained notification delegate support
arnaud-roland May 30, 2024
71e0bcb
expo: remove manual notification delegate in pre-build
arnaud-roland May 31, 2024
9baa0a1
profile: return promise from trackEvent to get errors in js side
arnaud-roland May 31, 2024
988093b
test: remove test since event attributes validation is done on native…
arnaud-roland May 31, 2024
d042a29
all: update changelog
arnaud-roland May 31, 2024
615e53b
all: bump version to 9.0.0
arnaud-roland May 31, 2024
42373e7
all: fix eslint
arnaud-roland May 31, 2024
01d9b6a
ios: avoid registering batch default delegate as previous one.
arnaud-roland Jun 4, 2024
cca01df
ios: fix native callback invoked twice
arnaud-roland Jun 4, 2024
f2fb551
ios: remove wrong delegate check
arnaud-roland Jun 13, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
50 changes: 49 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,53 @@
9.0.0
----

This is a major release, please see our [migration guide](https://doc.batch.com/react-native/advanced/8x-migration/) for more info on how to update your current Batch implementation.

**Plugin**
* Updated Batch to 2.0. For more information see the [ios](https://doc.batch.com/ios/sdk-changelog/#2_0_0) and [android](https://doc.batch.com/android/sdk-changelog/#2_0_0) changelog .
* Batch requires iOS 13.0 or higher.
* Batch requires a `minSdk` level of 21 or higher.

**iOS**
- The Batch React-Native plugin now automatically registers its own `UNUserNotificationCenterDelegate` and forwards it to the previous one if it exists.
This means you no longer need to add `[BatchUNUserNotificationCenterDelegate registerAsDelegate]` in your `AppDelegate`, please delete it.
It can be disabled by calling `BatchBridgeNotificationCenterDelegate.automaticallyRegister = false` before `[RNBatch start]`.


**Core**
- Added method `isOptedOut` to checks whether Batch has been opted out from or not.
- Added method `updateAutomaticDataCollection` to fine-tune the data you authorize to be tracked by Batch.

**User**
- Removed method `trackTransaction` with no equivalent.
- Removed method `BatchUser.editor` and the related class `BatchUserEditor`, you should now use `BatchProfile.editor` which return an instance of `BatchProfileAttributeEditor`.
- Added method `clearInstallationData` which allows you to remove the installation data without modifying the current profile.

**Event**

This version introduced two new types of attribute that can be attached to an event : Array and Object.

- Removed `trackEvent` APIs from the user module. You should now use `BatchProfile.trackEvent`.
- `BatchEventData` has been renamed into `BatchEventAttributes`.
- Removed `addTag` API from `BatchEventData` You should now use the `$tags` key with `put` method.
- Removed parameter `label` from `trackEvent` API. You should now use the `$label` key in `BatchEventAttributes` with the `put(string, string)` method.
- Added support for values of type: Array and Object to the `put` method.

**Profile**

Introduced `BatchProfile`, a new module that enables interacting with profiles. Its functionality replaces most of BatchUser used to do.

- Added `identify` API as replacement of `BatchUser.editor().setIdentifier`.
- Added `editor` method to get a new instance of a `BatchProfileAttributeEditor` as replacement of `BatchUserEditor`.
- Added `trackEvent` API as replacement of the `BatchUser.trackEvent` methods.
- Added `trackLocation` API as replacement of the `BatchUser.trackLocation` method.

**Expo**
- Added configuration field `enableDefaultOptOut` to control whether Batch is opted out from by default. (default: false)
- Added configuration fields `enableProfileCustomIDMigration` and `enableProfileCustomDataMigration` to control whether Batch should trigger the profile migrations (default: true).

8.2.0
____
----

**Plugin**

Expand Down
4 changes: 2 additions & 2 deletions RNBatchPush.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ Pod::Spec.new do |s|
s.authors = {
"Batch.com" => "support@batch.com"
}
s.platform = :ios, "12.0"
s.platform = :ios, "13.0"
s.source = { :git => "git@github.com:BatchLabs/Batch-React-Native-Plugin.git", :tag => "master" }
s.source_files = "ios/*.{h,m}"
s.requires_arc = true

s.dependency "React"
s.dependency 'Batch', '~> 1.21.0'
s.dependency 'Batch', '~> 2.0.0'
end
7 changes: 3 additions & 4 deletions android/build.gradle
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
def DEFAULT_MIN_SDK_VERSION = 16
def DEFAULT_MIN_SDK_VERSION = 21
def DEFAULT_COMPILE_SDK_VERSION = 34
def DEFAULT_BUILD_TOOLS_VERSION = "34.0.0"
def DEFAULT_TARGET_SDK_VERSION = 34
def DEFAULT_BATCH_SDK_VERSION = "1.21.+"
def DEFAULT_BATCH_SDK_VERSION = "2.0.+"

def safeExtGet(prop, fallback) {
rootProject.ext.has(prop) ? rootProject.ext.get(prop) : fallback
Expand All @@ -13,11 +13,10 @@ buildscript {
repositories {
mavenCentral()
google()
jcenter()
}

dependencies {
classpath("com.android.tools.build:gradle:8.2.0")
classpath("com.android.tools.build:gradle:8.2.2")
}
}
}
Expand Down
Loading
Loading