Read the statement by Michael Teeuw here.
Added getHeader function
-
Per request, I’ve added a
getHeader()method to the module api. This allows you to modify the header of the module from within the module itself.Note: that this method will only be called if the user has set a default header. If not no header will be shown and you won’t be able to update it.
Note: if you module’s users run an old version of MagicMirror (a version without this change), this method will not be called. No errors should be thrown. So it’s safe to use …
If you want to use the user’s set header in this method, just reference the
this.data.headervariable.Example code:
getHeader: function() { return this.data.header + ' append string'; }More info:
- Documentation: https://github.com/MichMich/MagicMirror/tree/develop/modules#getheader
- Commit: https://github.com/MichMich/MagicMirror/commit/b2a7d3584bad2752d59d2325c581f5018e875306
Please let me know if this feature works for you …
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login