Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
R
rn-apple-healthkit
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Jira
Jira
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
ym
rn-apple-healthkit
Commits
13e4959a
Commit
13e4959a
authored
Jun 28, 2016
by
Greg Wilson
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of github.com-GregWilson:GregWilson/react-native-apple-healthkit
parents
6d5dbe83
93892c11
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
23 additions
and
2 deletions
+23
-2
README.md
README.md
+23
-2
No files found.
README.md
View file @
13e4959a
...
...
@@ -3,9 +3,13 @@ A React Native bridge module for interacting with [Apple HealthKit] data.

#### Notice
*
This package is undergoing rapid development and should be considered unstable for the time being.
<strong>
Use at your own risk
</strong>
*
#### Table of Contents
*
[
Getting Started
](
#getting-started
)
*
[
Installation
](
#installation
-xcode
)
*
[
Installation
](
#installation
)
*
[
Usage
](
#usage
)
*
[
Documentation
](
#documentation
)
*
[
Permissions
](
#permissions
)
...
...
@@ -13,6 +17,7 @@ A React Native bridge module for interacting with [Apple HealthKit] data.
*
[
isAvailable
](
#isavailable
)
*
[
initHealthKit
](
#inithealthkit
)
*
[
getStepCountForToday
](
#getstepcountfortoday
)
*
[
getStepCountForDay
](
#getstepcountforday
)
*
[
getLatestWeight
](
#getlatestweight
)
*
[
saveWeight
](
#saveweight
)
*
[
getLatestHeight
](
#getlatestheight
)
...
...
@@ -169,7 +174,6 @@ AppleHealthKit.initHealthKit(healthKitOptions: object, (err: string, res: object
__
_
#### **`getStepCountForToday`**
get the the aggregated total steps for the current day starting and ending at midnight
```
javascript
...
...
@@ -183,6 +187,23 @@ AppleHealthKit.getStepCountForToday(null, (err: Object, steps: number) => {
__
_
#### **`getStepCountForDay`**
get the the aggregated total steps for the day provided as
`date`
in options object. the
`date`
field expects an ISO date string as its value
```
javascript
let
d
=
new
Date
(
2016
,
5
,
27
);
let
options
=
{
date
:
d
.
toISOString
()
};
AppleHealthKit
.
getStepCountForDay
(
options
,
(
err
,
steps
)
=>
{
if
(
this
.
_handleHealthKitError
(
err
,
'
getStepCountForDay
'
)){
return
;
}
// steps is the step count for day 'd'
});
```
__
_
#### **`getLatestWeight`**
get the most recent weight value
```
javascript
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment