Get the current user preferences.
Optionalkey: stringSupply the key for a specific preference to get only that value.
If a key is supplied, the value stored under that key is returned. If no key is supplied, an object with all preferences is returned instead.
Get the schema for the user preferences.
Set or delete the value for a specific user preference.
The key to store the value under.
Optionaldata: TThe data to save. Leave undefined to instead delete the currently stored value.
a promise that will be resolved when the data has been saved
Handle fetching and saving user preferences.