use factory

This commit is contained in:
Karsten Hassel
2021-07-05 19:45:58 +02:00
parent 179989aa42
commit bbb3accf0c
38 changed files with 152 additions and 152 deletions

View File

@@ -3,7 +3,9 @@
* By rejas
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
modules: [
{
module: "alert",
@@ -13,9 +15,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -24,9 +26,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -25,9 +27,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -24,9 +26,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rejas
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -24,9 +26,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -20,9 +22,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -5,7 +5,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -27,9 +29,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -22,9 +24,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rejas
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -21,9 +23,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Sergey Morozov
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -12,9 +14,7 @@ let config = {
position: "middle_center"
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,16 +3,16 @@
* By Sergey Morozov
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
modules: [
{
module: "clock",
position: "middle_center"
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -2,7 +2,9 @@
*
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
modules: [
{
module: "clock",
@@ -13,9 +15,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -15,9 +17,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Sergey Morozov
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -15,9 +17,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Johan Hammar
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -15,9 +17,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../../default.js')
const config = configFacory({
language: "es",
timeFormat: 12,
@@ -13,9 +15,7 @@ let config = {
position: "middle_center"
}
]
};
config = Object.assign(require("../../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../../default.js')
const config = configFacory({
language: "es",
modules: [
@@ -12,9 +14,7 @@ let config = {
position: "middle_center"
}
]
};
config = Object.assign(require("../../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../../default.js')
const config = configFacory({
language: "es",
timeFormat: 12,
@@ -16,9 +18,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -4,7 +4,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../../default.js')
const config = configFacory({
language: "es",
timeFormat: 12,
@@ -17,9 +19,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -20,9 +22,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rejas
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -21,9 +23,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -17,9 +19,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -19,9 +21,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rejas
* MIT Licensed.
*/
let config = {
const configFactory = require('../default.js')
let config = configFacory({
modules: [
{
module: "helloworld",
@@ -21,9 +23,8 @@ let config = {
}
}
]
};
});
config = Object.assign(require("../default.js"), config);
config.electronOptions.fullscreen = false;
config.electronOptions.width = 800;
config.electronOptions.height = 600;

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
modules: [
{
module: "helloworld",
@@ -13,9 +15,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,16 +3,16 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
modules: [
{
module: "helloworld",
position: "bottom_bar"
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -20,9 +22,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -2,7 +2,9 @@
*
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -19,9 +21,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -2,7 +2,9 @@
*
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -21,9 +23,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
const configFactory = require('../default.js')
const config = configFacory({
modules:
// Using exotic content. This is why don't accept go to JSON configuration file
(function () {
@@ -20,9 +22,7 @@ let config = {
}
return modules;
})()
};
config = Object.assign(require("../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By rejas https://github.com/rejas
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
modules: [
{
module: "compliments",
@@ -25,9 +27,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By fewieden https://github.com/fewieden
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -17,9 +19,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By fewieden https://github.com/fewieden
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
modules: [
{
module: "weather",
@@ -21,9 +23,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By fewieden https://github.com/fewieden
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
units: "imperial",
modules: [
@@ -19,9 +21,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By fewieden https://github.com/fewieden
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -19,9 +21,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By fewieden https://github.com/fewieden
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
timeFormat: 12,
modules: [
@@ -22,9 +24,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,7 +3,9 @@
* By rejas
* MIT Licensed.
*/
let config = {
const configFactory = require('../../default.js')
const config = configFacory({
units: "imperial",
modules: [
@@ -20,9 +22,7 @@ let config = {
}
}
]
};
config = Object.assign(require("../../default.js"), config);
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {

View File

@@ -3,12 +3,11 @@
* By Rodrigo Ramírez Norambuena https://rodrigoramirez.com
* MIT Licensed.
*/
let config = {
ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.10.1"]
};
const configFactory = require('./default.js')
config = Object.assign(require("./default.js"), config);
delete config.modules;
const config = configFacory({
ipWhitelist: ["127.0.0.1", "::ffff:127.0.0.1", "::1", "::ffff:192.168.10.1"]
});
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== "undefined") {