Skip to content

Releases: matinzd/react-native-health-connect

v2.0.2

03 May 10:40
0e5eda4
Compare
Choose a tag to compare

2.0.2 (2024-05-03)

Bug Fixes

v2.0.1

03 Mar 16:49
0679985
Compare
Choose a tag to compare

2.0.1 (2024-03-03)

Bug Fixes

  • Mapping between kilocalories and kilojoules (#68) (27768fc)

v2.0.0

22 Feb 18:04
Compare
Choose a tag to compare

2.0.0 (2024-02-22)

Bug Fixes

Features

BREAKING CHANGES

For version 2 onwards, please add the following code into your MainActivity.kt within the onCreate method:

package com.healthconnectexample

+ import android.os.Bundle
import com.facebook.react.ReactActivity
import com.facebook.react.ReactActivityDelegate
import com.facebook.react.defaults.DefaultNewArchitectureEntryPoint.fabricEnabled
import com.facebook.react.defaults.DefaultReactActivityDelegate
+ import dev.matinzd.healthconnect.permissions.HealthConnectPermissionDelegate

class MainActivity : ReactActivity() {
  /**
   * Returns the name of the main component registered from JavaScript. This is used to schedule
   * rendering of the component.
   */
  override fun getMainComponentName(): String = "HealthConnectExample"

+ override fun onCreate(savedInstanceState: Bundle?) {
+   super.onCreate(savedInstanceState)
+   // In order to handle permission contract results, we need to set the permission delegate.
+   HealthConnectPermissionDelegate.setPermissionDelegate(this)
+ }

  /**
   * Returns the instance of the [ReactActivityDelegate]. We use [DefaultReactActivityDelegate]
   * which allows you to enable New Architecture with a single boolean flags [fabricEnabled]
   */
  override fun createReactActivityDelegate(): ReactActivityDelegate =
    DefaultReactActivityDelegate(this, mainComponentName, fabricEnabled)
}

Ensure you have the latest patch of React Native installed to use v2, and use react-native version 0.71 and higher.

v1.2.3

18 Jan 16:57
Compare
Choose a tag to compare

1.2.3 (2024-01-18)

Bug Fixes

v1.2.2

21 Dec 09:02
Compare
Choose a tag to compare

What's Changed

  • chore: bump androidx.health.connect:connect-client to alpha06 by @matinzd in #53

Full Changelog: v1.2.1...v1.2.2

v1.2.1

12 Sep 14:28
Compare
Choose a tag to compare

What's Changed

  • fix(metadata): add recording method in the metadata object by @sauravexodus in #36
  • chore: bump androidx.health.connect:connect-client to alpha04 by @gewfy in #44

New Contributors

Full Changelog: v1.2.0...v1.2.1

v1.2.0

10 Aug 21:20
Compare
Choose a tag to compare

What's Changed

  • fix: peer dependency issue with expo config plugins by @matinzd in #30
  • fix: exerciseType typo by @Myst1024 in #31
  • chore: upgrade to alpha 1.1.0-alpha03 by @matinzd in #26

New Contributors

Full Changelog: v1.1.0...v1.2.0

v1.1.0

16 Jul 20:59
Compare
Choose a tag to compare

1.1.0 (2023-07-16)

Bug Fixes

  • peer dependency issue with expo config plugins (e515134)

Features

  • android: add support for react native 0.73 (6436d45)

v1.0.4

24 Jun 18:23
Compare
Choose a tag to compare

1.0.4 (2023-06-24)

Bug Fixes

  • add expo prebuild plugin to npm lib (280084b)

v1.0.3

22 Jun 22:35
Compare
Choose a tag to compare

What's Changed

  • chore(docs): fix small typos in getting started & aggregate record by @aarlin in #22
  • chore: app expo plugin configuration by @matinzd in #24
  • fix(types): request permission return type by @matinzd in #25

From now on, you can utilize the Expo plugin bundled with the library, thus eliminating the need for androidManifestPlugin.js. You can edit app.json file like this:

{
  "expo": {
    "plugins": ["react-native-health-connect"]
  }
}

New Contributors

Full Changelog: v1.0.2...v1.0.3