-
Notifications
You must be signed in to change notification settings - Fork 50
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* fix: xcframework builds * fix: import access level * feat: add sample xcframework project * fix: build examples * chore: update CHANGELOG
- Loading branch information
Showing
19 changed files
with
1,205 additions
and
31 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
// | ||
// ExternalSDK.swift | ||
// ExternalSDK | ||
// | ||
// Created by Yiannis Josephides on 24/01/2025. | ||
// | ||
|
||
import Foundation | ||
import PostHog | ||
|
||
public final class MyExternalSDK { | ||
public static let shared = MyExternalSDK() | ||
|
||
private init() { | ||
let config = PostHogConfig( | ||
apiKey: "phc_QFbR1y41s5sxnNTZoyKG2NJo2RlsCIWkUfdpawgb40D" | ||
) | ||
|
||
config.captureScreenViews = true | ||
config.captureApplicationLifecycleEvents = true | ||
config.debug = true | ||
config.sendFeatureFlagEvent = false | ||
config.sessionReplay = true | ||
config.sessionReplayConfig.maskAllImages = false | ||
config.sessionReplayConfig.maskAllTextInputs = false | ||
config.sessionReplayConfig.maskAllSandboxedViews = false | ||
|
||
PostHogSDK.shared.setup(config) | ||
} | ||
|
||
public func track(event: String) { | ||
PostHogSDK.shared.capture("An Event From ExternalSDK - \(event)") | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
// | ||
// ExternalSDK.h | ||
// ExternalSDK | ||
// | ||
// Created by Yiannis Josephides on 23/01/2025. | ||
// | ||
|
||
#import <Foundation/Foundation.h> | ||
|
||
//! Project version number for ExternalSDK. | ||
FOUNDATION_EXPORT double ExternalSDKVersionNumber; | ||
|
||
//! Project version string for TestBuildIssues. | ||
FOUNDATION_EXPORT const unsigned char ExternalSDKVersionString[]; | ||
|
||
// In this header, you should import all the public headers of your framework using statements like #import <TestBuildIssues/PublicHeader.h> | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
// swift-tools-version: 5.10 | ||
// The swift-tools-version declares the minimum version of Swift required to build this package. | ||
|
||
import PackageDescription | ||
|
||
let package = Package( | ||
name: "ExternalSDK", | ||
platforms: [.iOS(.v15)], | ||
products: [ | ||
.library( | ||
name: "ExternalSDK", | ||
targets: ["ExternalSDK-iOS"] | ||
), | ||
], | ||
dependencies: [ | ||
.package(path: "../"), | ||
], | ||
targets: [ | ||
.target( | ||
name: "ExternalSDK-iOS", | ||
dependencies: [ | ||
.product(name: "PostHog", package: "posthog-ios"), | ||
.target(name: "ExternalSDK"), | ||
] | ||
), | ||
.binaryTarget(name: "ExternalSDK", path: "./build/bin/ExternalSDK.xcframework"), | ||
] | ||
) |
Oops, something went wrong.