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
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@
## Requirements

This library is a **TurboModule** — it needs **React Native 0.84+** (New Architecture).
CI builds and tests against **RN 0.88**; 0.84–0.87 remain supported (no 0.88-only APIs are used).
**RN 0.6x / 0.7x / <0.84 are not supported** on either release line.

Pick a line by Android toolchain (HC SDK / AGP), not by RN major:
Expand All @@ -70,11 +71,11 @@ yarn add @solutionforest/android-health-connect@0.2.4 # AGP 8.9.1+ / compileSd
| Install | `@solutionforest/android-health-connect` from **npmjs.org** |
| Health Connect Jetpack SDK | [`connect-client:1.2.0-alpha06`](https://developer.android.com/jetpack/androidx/releases/health-connect) |
| Android Gradle Plugin | **9.1.1** (min **9.1.0**) |
| Gradle | **9.3.1+** (required by AGP 9.1) |
| Gradle | **9.3.1+** (required by AGP 9.1; RN 0.88 apps need **9.4.1+** for AGP 9.2) |
| compileSdk | **37** |
| Android OS | 10 (API 29)+ |
| Health Connect app | Required on Android 9–13; built-in on Android 14+ |
| React Native | **≥0.84** (New Architecture / TurboModules) — not 0.6x / 0.7x |
| React Native | **≥0.84** (New Architecture / TurboModules), tested on **0.88** — not 0.6x / 0.7x |
| Node.js | ≥22.22 |
| Expo (optional) | SDK 50+ |

Expand Down
2 changes: 1 addition & 1 deletion example/android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ buildscript {
mavenCentral()
}
dependencies {
classpath("com.android.tools.build:gradle:9.1.1")
classpath("com.android.tools.build:gradle:9.2.1")
classpath("com.facebook.react:react-native-gradle-plugin")
classpath("org.jetbrains.kotlin:kotlin-gradle-plugin:${kotlinVersion}")
}
Expand Down
2 changes: 1 addition & 1 deletion example/android/gradle/wrapper/gradle-wrapper.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
distributionUrl=https\://services.gradle.org/distributions/gradle-9.3.1-bin.zip
distributionUrl=https\://services.gradle.org/distributions/gradle-9.4.1-bin.zip
networkTimeout=10000
validateDistributionUrl=true
zipStoreBase=GRADLE_USER_HOME
Expand Down
16 changes: 8 additions & 8 deletions example/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,20 +10,20 @@
},
"dependencies": {
"react": "19.3.1",
"react-native": "0.84.1"
"react-native": "0.88.1"
},
"devDependencies": {
"@babel/core": "^8.1.3",
"@babel/preset-env": "^7.25.3",
"@babel/runtime": "^7.25.0",
"@react-native-community/cli": "20.1.0",
"@react-native-community/cli-platform-android": "20.1.0",
"@react-native/babel-preset": "0.84.1",
"@react-native/metro-config": "0.84.1",
"@react-native/typescript-config": "0.84.1",
"@react-native-community/cli": "20.2.0",
"@react-native-community/cli-platform-android": "20.2.0",
"@react-native/babel-preset": "0.88.1",
"@react-native/metro-config": "0.88.1",
"@react-native/typescript-config": "0.88.1",
"@types/react": "^19.2.0",
"react-native-builder-bob": "^0.40.18",
"react-native-monorepo-config": "^0.3.3"
"react-native-builder-bob": "^0.44.1",
"react-native-monorepo-config": "^0.4.0"
},
"engines": {
"node": ">=22.11.0"
Expand Down
11 changes: 6 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -95,8 +95,9 @@
"@eslint-community/eslint-plugin-eslint-comments": "^4.8.1",
"@eslint/compat": "^2.1.1",
"@expo/config-plugins": ">=8.0.0",
"@react-native/babel-preset": "0.84.1",
"@react-native/eslint-plugin": "0.84.1",
"@react-native/babel-preset": "0.88.1",
"@react-native/eslint-plugin": "0.88.1",
"@react-native/jest-preset": "0.88.1",
"@release-it/conventional-changelog": "^12.0.2",
"@types/jest": "^29.5.14",
"@types/react": "^19.2.0",
Expand All @@ -115,8 +116,8 @@
"lefthook": "^2.0.3",
"prettier": "^2.8.8",
"react": "19.3.1",
"react-native": "0.84.1",
"react-native-builder-bob": "^0.40.18",
"react-native": "0.88.1",
"react-native-builder-bob": "^0.44.1",
"react-test-renderer": "19.2.3",
"release-it": "^21.1.2",
"turbo": "^2.9.14",
Expand Down Expand Up @@ -174,7 +175,7 @@
"useTabs": false
},
"jest": {
"preset": "react-native",
"preset": "@react-native/jest-preset",
"modulePathIgnorePatterns": [
"<rootDir>/example/node_modules",
"<rootDir>/lib/"
Expand Down
5 changes: 3 additions & 2 deletions src/helpers.ts
Original file line number Diff line number Diff line change
Expand Up @@ -283,9 +283,10 @@ export type PollUntilResult<T> = {
};

function abortError(signal?: AbortSignal): Error {
const reason =
// RN 0.88's AbortSignal typings expose `reason` as `any`; narrow to unknown.
const reason: unknown =
signal !== undefined && 'reason' in signal
? (signal as AbortSignal & { reason?: unknown }).reason
? (signal as { reason?: unknown }).reason
: undefined;
return reason instanceof Error ? reason : new Error('Aborted');
}
Expand Down
Loading