new Preferences()
Manage the user preferences
Methods
-
<static> getInstance()
-
Singleton instance of the preferences
-
read( [options] [, callback])
-
Read the preferences
Parameters:
Name Type Argument Description options
Object <optional>
Properties
Name Type Argument Default Description silent
Boolean <optional>
false By pass the output
callback
function <optional>
Callback
Properties
Name Type Argument Description preferences
Object | null <optional>
Properties
Name Type Argument Description author
Object <optional>
Default ADX author
Properties
Name Type Argument Description name
String <optional>
Default Name of the ADX author
email
String <optional>
Default Email of the ADX author
company
String <optional>
Default Company of the ADX author
webSite
String <optional>
Default WebSite of the ADX author
ZenDesk
Object <optional>
Default ZenDesk options
Properties
Name Type Argument Description url
String <optional>
Default ZenDesk URL
section
String <optional>
Default ZenDesk section
username
String <optional>
Default ZenDesk username
password
String <optional>
Default ZenDesk password
promoted
String <optional>
ZenDesk: create promoted article on article by default
disabledComments
String <optional>
ZenDesk: disabled article comments by default
-
write(preferences [, callback])
-
Write the preferences
Parameters:
Name Type Argument Description preferences
Object Properties
Name Type Argument Description author
Object <optional>
Default ADX author
Properties
Name Type Argument Description name
String <optional>
Default Name of the ADX author
email
String <optional>
Default Email of the ADX author
company
String <optional>
Default Company of the ADX author
webSite
String <optional>
Default WebSite of the ADX author
callback
function <optional>
Callback
Properties
Name Type Argument Description preferences
Object | null <optional>
Properties
Name Type Argument Description author
Object <optional>
Default ADX author
Properties
Name Type Argument Description name
String <optional>
Default Name of the ADX author
email
String <optional>
Default Email of the ADX author
company
String <optional>
Default Company of the ADX author
website
String <optional>
Default Website of the ADX author
ZenDesk
Object <optional>
Default ZenDesk options
Properties
Name Type Argument Description url
String <optional>
Default ZenDesk URL
section
String <optional>
Default ZenDesk section
username
String <optional>
Default ZenDesk username
password
String <optional>
Default ZenDesk password
promoted
String <optional>
ZenDesk: create promoted article on article by default
disabledComments
String <optional>
ZenDesk: disabled article comments by default