Skip to content
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

CHNL-12052: Update to include SDK name and version in network requests #175

Merged
merged 8 commits into from
Sep 25, 2024

Conversation

ajaysubra
Copy link
Collaborator

Description

⚠️ Merge after klaviyo/klaviyo-swift-sdk#204 ⚠️

Does two things,

  1. Adds the plist klaviyo-react-native-sdk-configuration.plist to the iOS directory.
  2. Includes the above plist as a resource in the podspec.

Slightly unrelated but updated the breaking changes from the swift SDK and pushing them as well. FYI @ab1470

Test Plan

Tested locally by pulling in local version of Swift SDK and using the internal test app.

@ajaysubra ajaysubra requested a review from a team as a code owner September 19, 2024 20:02
@ajaysubra ajaysubra requested review from ndurell, evan-masseau and ab1470 and removed request for a team September 19, 2024 20:02
<key>react_native_sdk_name</key>
<string>react_native</string>
<key>react_native_sdk_version</key>
<string>9.8.8</string>
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

9.8.8 ?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think we have a release doc pertaining to RN, lets make sure we update it to mention this is another spot the version needs to get incremented before release

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🤦🏾 I'm glad I used a crazy version for testing. Fixed it to 1.0.0 assuming it's going to be the next release. Good call, I update the confluence doc with this step.

@ajaysubra ajaysubra changed the title As/chnl 12052 update to send sdk name and version CHNL-12052: Update to include SDK name and version in network requests Sep 19, 2024
@@ -13,6 +13,7 @@ Pod::Spec.new do |s|
s.platforms = { :ios => "13.0" }
s.source = { :git => "https://github.com/klaviyo/klaviyo-react-native-sdk.git", :tag => "#{s.version}" }
s.source_files = "ios/**/*.{h,m,mm,swift}"
s.resources = ["ios/klaviyo-react-native-sdk-configuration.plist"]
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is no spm equivalent of this or that's not needed right?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hmm, didn't think about SPM. I think since we are including KlaviyoSwift SDK in the podspec and also since RN only supports cocoapods we should be good. Also, there is no package file in RN, there is no way to add this plist as a resource.

Comment on lines 34 to 37
"VIEWED_PRODUCT": Event.EventName.viewedProductMetric.value,
"STARTED_CHECKOUT": Event.EventName.startedCheckoutMetric.value,
"OPENED_APP": Event.EventName.openedAppMetric.value,
"ADDED_TO_CART": Event.EventName.addedToCartMetric.value
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks! 🙏🏻

@ajaysubra ajaysubra merged commit 61d6449 into master Sep 25, 2024
8 of 9 checks passed
@ajaysubra ajaysubra deleted the as/chnl-12052-update-to-send-sdk-name-and-version branch September 25, 2024 17:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants