MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    1. Home
    2. Oboudreaux
    3. Best
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.
    O
    Offline
    • Profile
    • Following 0
    • Followers 0
    • Topics 0
    • Posts 2
    • Groups 0

    Posts

    Recent Best Controversial
    • RE: Default Modules

      A little improvement on compliments: a day of the week category.

      const day = moment().format("dddd");
      ...
      if (day in this.config.compliments) {
                    compliments.push.apply(compliments, this.config.compliments[day])
      }
      

      allows entries like:

      "Monday" : [
          "Looks like somebody has a case of the Mondays"
      ],
      "Tuesday" : [
          "Take out the trash."
      ]
      

      Sorry, I didn’t see a better place to drop this

      posted in Modules
      O
      Oboudreaux
    • 1 / 1