Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
2 changes: 1 addition & 1 deletion android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ dependencies {
testImplementation 'org.jetbrains.kotlin:kotlin-test'
testImplementation 'org.mockito:mockito-core:5.0.0'

implementation 'com.frontegg.sdk:android:1.3.25'
implementation 'com.frontegg.sdk:android:1.3.26'
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-android:1.7.3'

implementation 'androidx.core:core-ktx:1.10.0'
Expand Down
4 changes: 3 additions & 1 deletion application_id/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,8 @@ android {
buildConfigField "String", 'FRONTEGG_APPLICATION_ID', "\"$fronteggApplicationId\""
buildConfigField "Boolean", 'FRONTEGG_USE_ASSETS_LINKS', "true"
buildConfigField "Boolean", 'FRONTEGG_USE_CHROME_CUSTOM_TABS', "true"
// Set to true to disable automatic token refresh.
buildConfigField "boolean", "FRONTEGG_DISABLE_AUTO_REFRESH", "false"

testInstrumentationRunner "pl.leancode.patrol.PatrolJUnitRunner"
testInstrumentationRunnerArguments clearPackageData: "true"
Expand Down Expand Up @@ -126,5 +128,5 @@ flutter {

dependencies {
androidTestUtil "androidx.test:orchestrator:1.5.1"
implementation 'com.frontegg.sdk:android:1.3.25'
implementation 'com.frontegg.sdk:android:1.3.26'
}
3 changes: 3 additions & 0 deletions application_id/ios/Runner/Frontegg.plist
Original file line number Diff line number Diff line change
Expand Up @@ -14,5 +14,8 @@
<string>f717b75f-e09a-48cc-a84e-e20a8454a9cf</string>
<key>logLevel</key>
<string>trace</string>
<!-- Set to true to disable automatic token refresh -->
<key>disableAutoRefresh</key>
<false/>
</dict>
</plist>
2 changes: 1 addition & 1 deletion docs/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Sign up here → [https://portal.us.frontegg.com/signup](https://portal.us.front

The Flutter SDK supports Frontegg's **per-tenant sessions** feature through the underlying native SDKs.

- On **Android**, the plugin and example apps use `com.frontegg.sdk:android:1.3.25`.
- On **Android**, the plugin and example apps use `com.frontegg.sdk:android:1.3.26`.
- On **iOS**, the plugin depends on `FronteggSwift`:
- **Flutter 3.41+** (SPM): `1.3.0` from GitHub. Run `flutter config --enable-swift-package-manager`, then `flutter pub get` and build.
- Note: CocoaPods fallback is no longer supported for `FronteggSwift`.
Expand Down
23 changes: 23 additions & 0 deletions docs/usage.md
Original file line number Diff line number Diff line change
Expand Up @@ -245,6 +245,29 @@ When `FRONTEGG_ENABLE_OFFLINE_MODE` is `true`, the SDK keeps the session with st

**Optional:** if you rely on auto-reconnect after offline, you can tune the ContentProvider debounce via manifest metadata on `com.frontegg.android.init.FronteggInitProvider` (`frontegg.autoreconnect.debounceMs`), as documented for the Android SDK.

#### Disable automatic token refresh

You can disable automatic token refresh in Flutter projects through the native SDK configuration.

Android (`android/app/build.gradle`):

```groovy
buildConfigField "boolean", "FRONTEGG_DISABLE_AUTO_REFRESH", "true"
```

iOS (`Frontegg.plist`):

```xml
<key>disableAutoRefresh</key>
<true/>
```

Behavior:

- Default is `false` (automatic refresh stays enabled).
- When enabled, SDK internal/automatic refresh flows are blocked (including timer-based/background auto refresh).
- Manual refresh APIs are still available (for example, `await frontegg.refreshToken()`).

You can access the current state of `FronteggFlutter` in two ways:

1. Get `currentState`:
Expand Down
4 changes: 3 additions & 1 deletion embedded/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,8 @@ android {
buildConfigField "String", 'FRONTEGG_DEEP_LINK_SCHEME', "\"test\""
buildConfigField "boolean", "FRONTEGG_ENABLE_OFFLINE_MODE", "true"
buildConfigField "int", "FRONTEGG_NETWORK_MONITORING_INTERVAL_SECONDS", "10"
// Set to true to disable automatic token refresh.
buildConfigField "boolean", "FRONTEGG_DISABLE_AUTO_REFRESH", "true"

testInstrumentationRunner "pl.leancode.patrol.PatrolJUnitRunner"
testInstrumentationRunnerArguments clearPackageData: "true"
Expand Down Expand Up @@ -126,5 +128,5 @@ flutter {

dependencies {
androidTestUtil "androidx.test:orchestrator:1.5.1"
implementation 'com.frontegg.sdk:android:1.3.25'
implementation 'com.frontegg.sdk:android:1.3.26'
}
4 changes: 2 additions & 2 deletions embedded/ios/Podfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,8 @@ EXTERNAL SOURCES:
SPEC CHECKSUMS:
CocoaAsyncSocket: 065fd1e645c7abab64f7a6a2007a48038fdc6a99
Flutter: cabc95a1d2626b1b06e7179b784ebcf0c0cde467
fluttertoast: 21eecd6935e7064cc1fcb733a4c5a428f3f24f0f
patrol: cf2cd48c7f3e5171610111994f7b466cd76d1f57
fluttertoast: 2c67e14dce98bbdb200df9e1acf610d7a6264ea1
patrol: 51b76cc7c11a2933ee3e72482d930c75b9d4ec73

PODFILE CHECKSUM: c9be09f6a61958d6788db8b9ee489767b65cfa92

Expand Down

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions embedded/ios/Runner/Frontegg.plist
Original file line number Diff line number Diff line change
Expand Up @@ -21,5 +21,8 @@
<true/>
<key>networkMonitoringInterval</key>
<integer>10</integer>
<!-- Set to true to disable automatic token refresh -->
<key>disableAutoRefresh</key>
<true/>
</dict>
</plist>
2 changes: 1 addition & 1 deletion embedded/lib/main_page.dart
Original file line number Diff line number Diff line change
Expand Up @@ -103,4 +103,4 @@ class MainPage extends StatelessWidget {
),
);
}
}
}
4 changes: 3 additions & 1 deletion hosted/android/app/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@ android {
buildConfigField "String", 'FRONTEGG_CLIENT_ID', "\"$fronteggClientId\""
buildConfigField "Boolean", 'FRONTEGG_USE_ASSETS_LINKS', "true"
buildConfigField "Boolean", 'FRONTEGG_USE_CHROME_CUSTOM_TABS', "true"
// Set to true to disable automatic token refresh.
buildConfigField "boolean", "FRONTEGG_DISABLE_AUTO_REFRESH", "false"

testInstrumentationRunner "pl.leancode.patrol.PatrolJUnitRunner"
testInstrumentationRunnerArguments clearPackageData: "true"
Expand Down Expand Up @@ -122,5 +124,5 @@ flutter {

dependencies {
androidTestUtil "androidx.test:orchestrator:1.5.1"
implementation 'com.frontegg.sdk:android:1.3.25'
implementation 'com.frontegg.sdk:android:1.3.26'
}
3 changes: 3 additions & 0 deletions hosted/ios/Runner/Frontegg.plist
Original file line number Diff line number Diff line change
Expand Up @@ -10,5 +10,8 @@
<string>5f493de4-01c5-4a61-8642-fca650a6a9dc</string>
<key>logLevel</key>
<string>trace</string>
<!-- Set to true to disable automatic token refresh -->
<key>disableAutoRefresh</key>
<false/>
</dict>
</plist>
2 changes: 1 addition & 1 deletion ios/frontegg_flutter/Package.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ let package = Package(
],
dependencies: [
.package(name: "FlutterFramework", path: "../FlutterFramework"),
.package(url: "https://github.com/frontegg/frontegg-ios-swift.git", exact: "1.3.0"),
.package(url: "https://github.com/frontegg/frontegg-ios-swift.git", exact: "1.3.2"),
],
targets: [
.target(
Expand Down
Loading