Skip to content
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
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
1 change: 1 addition & 0 deletions analysis_options.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
include: package:flutter_lints/flutter.yaml
7 changes: 4 additions & 3 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -2,14 +2,14 @@ group = "id.oddbit.flutter.facebook_app_events"
version = "1.0-SNAPSHOT"

buildscript {
ext.kotlin_version = "1.9.24"
ext.kotlin_version = "2.3.10"
repositories {
google()
mavenCentral()
}

dependencies {
classpath("com.android.tools.build:gradle:8.5.2")
classpath("com.android.tools.build:gradle:8.9.2")
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version")
}
}
Expand All @@ -27,7 +27,7 @@ apply plugin: "kotlin-android"
android {
namespace "id.oddbit.flutter.facebook_app_events"

compileSdk = 34
compileSdk = 35

compileOptions {
sourceCompatibility = JavaVersion.VERSION_17
Expand All @@ -48,6 +48,7 @@ android {

defaultConfig {
minSdk = 21
consumerProguardFiles 'consumer-proguard-rules.pro'
}

dependencies {
Expand Down
4 changes: 4 additions & 0 deletions android/consumer-proguard-rules.pro
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# Preserve Facebook App Events SDK classes used by this plugin.
# Without this rule, R8 in the host app may strip classes that are only
# referenced reflectively by the Facebook SDK, causing runtime crashes.
-keep class com.facebook.appevents.** { *; }
3 changes: 3 additions & 0 deletions android/gradle.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
org.gradle.parallel=true
org.gradle.caching=true
android.nonTransitiveRClass=true
4 changes: 2 additions & 2 deletions android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@ distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
# AGP 8.5.x pairs with Gradle 8.7
distributionUrl=https\://services.gradle.org/distributions/gradle-8.7-bin.zip
# AGP 8.9.x pairs with Gradle 8.11.1
distributionUrl=https\://services.gradle.org/distributions/gradle-8.11.1-bin.zip
4 changes: 2 additions & 2 deletions ios/facebook_app_events.podspec
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,8 @@ Flutter plugin for Facebook Analytics and App Events
s.source_files = 'facebook_app_events/Sources/facebook_app_events/**/*.{swift}'
s.static_framework = true
s.dependency 'Flutter'
s.swift_version = '5.0'
s.ios.deployment_target = '12.0'
s.swift_version = '5.9'
s.ios.deployment_target = '13.0'

# Do not specify PATCH version of FBSDKCoreKit. See README file for explanation
# https://github.com/oddbit/flutter_facebook_app_events#dependencies-on-facebook-sdk
Expand Down
6 changes: 3 additions & 3 deletions ios/facebook_app_events/Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -3,22 +3,22 @@
// This source file is part of facebook_app_events.
// Licensed under the Apache License, Version 2.0. See LICENSE and NOTICE.

// swift-tools-version: 5.9
// swift-tools-version: 6.1
// The swift-tools-version declares the minimum version of Swift required to build this package.

import PackageDescription

let package = Package(
name: "facebook_app_events",
platforms: [
.iOS(.v12)
.iOS(.v13)
],
products: [
// If the plugin name contains "_", the library name must use "-".
.library(name: "facebook-app-events", targets: ["facebook_app_events"])
],
dependencies: [
.package(url: "https://github.com/facebook/facebook-ios-sdk.git", from: "18.0.0")
.package(url: "https://github.com/facebook/facebook-ios-sdk.git", "18.0.0"..<"19.0.0")
],
targets: [
.target(
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ public class FacebookAppEventsPlugin: NSObject, FlutterPlugin {
case "logPurchase":
handlePurchased(call, result: result)
case "getAnonymousId":
handleHandleGetAnonymousId(call, result: result)
handleGetAnonymousId(call, result: result)
case "setAdvertiserTracking":
handleSetAdvertiserTracking(call, result: result)
case "setGraphApiVersion":
Expand Down Expand Up @@ -127,7 +127,7 @@ public class FacebookAppEventsPlugin: NSObject, FlutterPlugin {
result(appId)
}

private func handleHandleGetAnonymousId(_ call: FlutterMethodCall, result: @escaping FlutterResult) {
private func handleGetAnonymousId(_ call: FlutterMethodCall, result: @escaping FlutterResult) {
result(AppEvents.shared.anonymousID)
}

Expand Down
5 changes: 3 additions & 2 deletions pubspec.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ version: 0.25.0
homepage: https://github.com/oddbit/flutter_facebook_app_events

environment:
sdk: '>=2.12.0 <4.0.0'
flutter: '>=2.0.0'
sdk: '>=3.3.0 <4.0.0'
flutter: '>=3.19.0'
Comment on lines 7 to +9
Copy link

Copilot AI Mar 12, 2026

Choose a reason for hiding this comment

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

The SDK/Flutter constraints were tightened (Dart >=3.3.0, Flutter >=3.19.0), which is a breaking change for consumers. The package version is still 0.25.0; please bump the pubspec version (and update the changelog/release notes accordingly) so the published package reflects the new minimum toolchain requirements.

Copilot uses AI. Check for mistakes.
Copy link
Member Author

Choose a reason for hiding this comment

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

Acknowledged — version bump and changelog will be handled separately at release time, not as part of this toolchain PR.


dependencies:
flutter:
Expand All @@ -15,6 +15,7 @@ dependencies:
dev_dependencies:
flutter_test:
sdk: flutter
flutter_lints: ^5.0.0

flutter:
plugin:
Expand Down
Loading