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
5005b86a
Commit
5005b86a
authored
Jun 28, 2016
by
Greg Wilson
Committed by
GitHub
Jun 28, 2016
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
some fixes
parent
6e97ba39
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
README.md
README.md
+4
-4
No files found.
README.md
View file @
5005b86a
...
@@ -50,7 +50,7 @@ var AppleHealthKit = require('react-native-apple-healthkit');
...
@@ -50,7 +50,7 @@ var AppleHealthKit = require('react-native-apple-healthkit');
let
healthKitOptions
=
{
let
healthKitOptions
=
{
permissions
:
{
permissions
:
{
read
:
[
"
Height
"
,
"
Weight
"
,
"
Steps
"
,
"
DateOfBirth
"
,
"
BodyMassIndex
"
],
read
:
[
"
Height
"
,
"
Weight
"
,
"
Steps
"
,
"
DateOfBirth
"
,
"
BodyMassIndex
"
],
write
:
[
"
Weight
"
,
"
Steps
"
]
write
:
[
"
Weight
"
,
"
Steps
"
,
"
BodyMassIndex
"
]
}
}
};
};
...
@@ -74,7 +74,7 @@ var _ = require('lodash');
...
@@ -74,7 +74,7 @@ var _ = require('lodash');
...
...
AppleHealthKit
.
get
Curren
tWeight
(
null
,
(
err
,
weight
)
=>
{
AppleHealthKit
.
get
Lates
tWeight
(
null
,
(
err
,
weight
)
=>
{
if
(
err
){
if
(
err
){
console
.
log
(
"
error getting current weight:
"
,
err
);
console
.
log
(
"
error getting current weight:
"
,
err
);
return
;
return
;
...
@@ -86,7 +86,7 @@ AppleHealthKit.getCurrentWeight(null, (err, weight) => {
...
@@ -86,7 +86,7 @@ AppleHealthKit.getCurrentWeight(null, (err, weight) => {
...
...
let
myWeight
=
200
;
let
myWeight
=
200
;
AppleHealthKit
.
saveWeight
({
weight
:
myWeight
},
(
err
,
res
)
=>
{
AppleHealthKit
.
saveWeight
({
value
:
myWeight
},
(
err
,
res
)
=>
{
if
(
err
){
if
(
err
){
console
.
log
(
"
error saving weight to healthkit:
"
,
err
);
console
.
log
(
"
error saving weight to healthkit:
"
,
err
);
return
;
return
;
...
@@ -150,7 +150,7 @@ initialize HealthKit. this will show the HealthKit permissions prompt for any re
...
@@ -150,7 +150,7 @@ initialize HealthKit. this will show the HealthKit permissions prompt for any re
let
healthKitOptions
=
{
let
healthKitOptions
=
{
permissions
:
{
permissions
:
{
read
:
[
"
Height
"
,
"
Weight
"
,
"
Steps
"
,
"
DateOfBirth
"
,
"
BodyMassIndex
"
],
read
:
[
"
Height
"
,
"
Weight
"
,
"
Steps
"
,
"
DateOfBirth
"
,
"
BodyMassIndex
"
],
write
:
[
"
Weight
"
]
write
:
[
"
Weight
"
,
"
Steps
"
,
"
BodyMassIndex
"
]
}
}
};
};
```
```
...
...
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