Skip to content

gregoiresage/fitbit-shared-preferences

 
 

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Preferences for Fitbit

Memory cached and persistent key-value local storage for Fitbit OS.

Usage

Install the module:

npm i fitbit-preferences

Import the script:

import { preferences } from "fitbit-preferences";

Store your values:

preferences.keep_screen_on = true;
preferences.user_name = "John Doe";
preferences.birth_year = 1988;

Read your values:

let keepScreenOn = preferences.keep_screen_on;
let userName = preferences.user_name;
let birthYear = preferences.birth_year;

The script loads the data automatically on start, and saves it on close.

And that's all!

About

Android-like persistent key-value storage for Fitbit SDK

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • JavaScript 100.0%