mirror of
https://github.com/MichMich/MagicMirror.git
synced 2025-08-21 12:55:22 +00:00
Merge branch 'develop' into master
This commit is contained in:
@@ -356,7 +356,7 @@ Module.register("calendar", {
|
||||
return a.startDate - b.startDate;
|
||||
});
|
||||
|
||||
return events;
|
||||
return events.slice(0, this.config.maximumEntries);
|
||||
},
|
||||
|
||||
/* createEventList(url)
|
||||
|
5
modules/default/helloworld/helloworld.html
Normal file
5
modules/default/helloworld/helloworld.html
Normal file
@@ -0,0 +1,5 @@
|
||||
<!--
|
||||
Use ` | safe` to allow html tages within the text string.
|
||||
https://mozilla.github.io/nunjucks/templating.html#autoescaping
|
||||
-->
|
||||
<div>{{text | safe}}</div>
|
@@ -14,10 +14,11 @@ Module.register("helloworld",{
|
||||
text: "Hello World!"
|
||||
},
|
||||
|
||||
// Override dom generator.
|
||||
getDom: function() {
|
||||
var wrapper = document.createElement("div");
|
||||
wrapper.innerHTML = this.config.text;
|
||||
return wrapper;
|
||||
getTemplate: function () {
|
||||
return "helloworld.html"
|
||||
},
|
||||
|
||||
getTemplateData: function () {
|
||||
return this.config
|
||||
}
|
||||
});
|
||||
|
Reference in New Issue
Block a user