Load, save and apply options to HTML options page.
- Source:
- Source:
- Source:
Requires
Methods
(static) init(optionsopt) → {Promise}
- Source:
Initializes the options, loads them and sets everything up.
Parameters:
Name | Type | Attributes | Description | ||||||||
---|---|---|---|---|---|---|---|---|---|---|---|
options |
Object |
<optional> |
Properties
|
Returns:
- Type
- Promise
(static) setDefaultOptionProvider(defaultOptionCallback) → {void}
- Source:
Sets the callback for getting the default options.
See defaultOptionGetterCallback
for how the callback needs to
behave.
You need to call this function before the main init function of
AutomaticSettings. However, if you do not want to specify defaults
in JS, but just in HTML, you can pass "null" to this and it will not
try to request defaults.
Pass "undefined" to it to unset it.
Parameters:
Name | Type | Description |
---|---|---|
defaultOptionCallback |
defaultOptionGetterCallback | null |
Returns:
- Type
- void