From 0687bc529e30e10c496669c15cb87f3caf4af0c8 Mon Sep 17 00:00:00 2001 From: skleest Date: Thu, 30 Mar 2017 14:13:52 -0700 Subject: [PATCH] update readme more --- README.md | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index f0d18b5..feb89c8 100644 --- a/README.md +++ b/README.md @@ -916,7 +916,6 @@ AppleHealthKit.getSleepSamples(options, (err: Object, samples: Array) => ___ #### **`saveMindfulSession`** -saveMindfulSession each mindfulness sample represents a period of time with a startDate and an endDate. the options must contain `startDate` and `endDate` @@ -926,6 +925,14 @@ let options = { startDate: (new Date(2016,10,1)).toISOString(), // required endDate: (new Date()).toISOString(), // optional; default now }; + +AppleHealthKit.saveMindfulSession({ + startDate: startDate, + endDate: endDate +}, (err, res) => { + if (err) return console.log(err) + console.log('Mindful session saved') +}); ``` -- 2.26.2