mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-06-27 11:50:00 +00:00
Cleanup jsdoc
This commit is contained in:
parent
67bedf8648
commit
efafb1c28a
33
js/module.js
33
js/module.js
@ -228,7 +228,7 @@ var Module = Class.extend({
|
||||
* Set the module config and combine it with the module defaults.
|
||||
*
|
||||
* @param {object} config The combined module config.
|
||||
* @param {boolean} config Merge module config in deep.
|
||||
* @param {boolean} deep Merge module config in deep.
|
||||
*/
|
||||
setConfig: function (config, deep) {
|
||||
this.config = deep ? configMerge({}, this.defaults, config) : Object.assign({}, this.defaults, config);
|
||||
@ -429,20 +429,27 @@ var Module = Class.extend({
|
||||
options = options || {};
|
||||
|
||||
var self = this;
|
||||
MM.showModule(this, speed, function () {
|
||||
self.resume();
|
||||
callback();
|
||||
}, options);
|
||||
MM.showModule(
|
||||
this,
|
||||
speed,
|
||||
function () {
|
||||
self.resume();
|
||||
callback();
|
||||
},
|
||||
options
|
||||
);
|
||||
}
|
||||
});
|
||||
|
||||
/** Merging MagicMirror (or other) default/config script
|
||||
* merge 2 objects or/with array
|
||||
* using:
|
||||
/**
|
||||
* Merging MagicMirror (or other) default/config script by @bugsounet
|
||||
* Merge 2 objects or/with array
|
||||
*
|
||||
* Usage:
|
||||
* -------
|
||||
* this.config = configMerge({}, this.defaults, this.config)
|
||||
* -------
|
||||
* arg1: initial objet
|
||||
* arg1: initial object
|
||||
* arg2: config model
|
||||
* arg3: config to merge
|
||||
* -------
|
||||
@ -451,10 +458,12 @@ var Module = Class.extend({
|
||||
* it don't merge all thing in deep
|
||||
* -> object in object and array is not merging
|
||||
* -------
|
||||
* @bugsounet
|
||||
* @Todo: idea of Mich determinate what do you want to merge or not
|
||||
*
|
||||
* Todo: idea of Mich determinate what do you want to merge or not
|
||||
*
|
||||
* @param {object} result the initial object
|
||||
* @returns {object} the merged config
|
||||
*/
|
||||
|
||||
function configMerge(result) {
|
||||
var stack = Array.prototype.slice.call(arguments, 1);
|
||||
var item;
|
||||
|
Loading…
x
Reference in New Issue
Block a user