MagicMirror Forum
    • Recent
    • Tags
    • Unsolved
    • Solved
    • MagicMirror² Repository
    • Documentation
    • 3rd-Party-Modules
    • Donate
    • Discord
    • Register
    • Login
    A New Chapter for MagicMirror: The Community Takes the Lead
    Read the statement by Michael Teeuw here.

    mmm Dad Jokes

    Scheduled Pinned Locked Moved Unsolved Troubleshooting
    13 Posts 5 Posters 4.4k Views 4 Watching
    Loading More Posts
    • Oldest to Newest
    • Newest to Oldest
    • Most Votes
    Reply
    • Reply as topic
    Log in to reply
    This topic has been deleted. Only users with topic management privileges can see it.
    • B Offline
      bokow
      last edited by

      Still have not got it to work, Here are the errors:
      SyntaxError: Unexpected token var
      at new Script (vm.js:74:7)
      at createScript (vm.js:246:10)
      at Object.runInThisContext (vm.js:298:10)
      at Module._compile (internal/modules/cjs/loader.js:678:28)
      at Object.Module._extensions…js (internal/modules/cjs/loader.js:722:10)
      at Module.load (internal/modules/cjs/loader.js:620:32)
      at tryModuleLoad (internal/modules/cjs/loader.js:559:12)
      at Function.Module._load (internal/modules/cjs/loader.js:551:3)
      at Module.require (internal/modules/cjs/loader.js:658:17)
      at require (internal/modules/cjs/helpers.js:20:18)

      bheplerB 1 Reply Last reply Reply Quote 0
      • bheplerB Offline
        bhepler Module Developer @bokow
        last edited by

        @bokow - Copy & paste your relevant config.js entry for MMM-Dad-Jokes here and we’ll take a quick look at it. Remember to use the markdown features of the board.

        1 Reply Last reply Reply Quote 0
        • B Offline
          bokow
          last edited by

          /* Magic Mirror Config Sample
          *

          • By Michael Teeuw http://michaelteeuw.nl
          • MIT Licensed.
          • For more information how you can configurate this file
          • See https://github.com/MichMich/MagicMirror#configuration

          */

          var config = {
          address: “localhost”, // Address to listen on, can be:
          // - “localhost”, “127.0.0.1”, “::1” to listen on loopback interface
          // - another specific IPv4/6 to listen on a specific interface
          // - “”, “0.0.0.0”, “::” to listen on any interface
          // Default, when address config is left out, is “localhost”
          port: 8080,
          ipWhitelist: [“127.0.0.1”, “::ffff:127.0.0.1”, “::1”], // Set [] to allow all IP addresses
          // or add a specific IPv4 of 192.168.1.5 :
          // [“127.0.0.1”, “::ffff:127.0.0.1”, “::1”, “::ffff:192.168.1.5”],
          // or IPv4 range of 192.168.3.0 --> 192.168.3.15 use CIDR format :
          // [“127.0.0.1”, “::ffff:127.0.0.1”, “::1”, “::ffff:192.168.3.0/28”],

          language: "en",
          timeFormat: 24,
          units: "metric",
          
          modules: [
          	{
          		module: "alert",
          	},
          	{
          		module: "updatenotification",
          		position: "top_bar"
          	},
          	
          	{
                  module: 'MMM-icanhazdadjoke',
                  position: 'bottom_right',
                  config: {
                      // See below for configurable options
                  	}
              		},
          	{	
          		module: "clock",
          		position: "top_left"
          	},
          	{
          		module: "calendar",
          		header: "US Holidays",
          		position: "top_left",
          		config: {
          			calendars: [
          				{
          					symbol: "calendar-check",
          					url: "webcal://www.calendarlabs.com/templates/ical/US-Holidays.ics"
          				}
          			]
          		}
          	},
          	{
          		module: "compliments",
          		position: "lower_third"
          	},
          	{
          		module: "currentweather",
          		position: "top_right",
          		config: {
          			location: "Saginaw",
          			locationID: "5007989",  //ID from http://bulk.openweathermap.org/sample/; unzip the gz file and find your city
          			appid: "90f012418925c43d4ac4e54f147c53be"
          		}
          	},
          	{
          		module: "weatherforecast",
          		position: "top_right",
          		header: "Weather Forecast",
          		config: {
          			location: "Saginaw",
          			locationID: "5007989",  //ID from https://openweathermap.org/city
          			appid: "90f012418925c43d4ac4e54f147c53be"
          		}
          	},
          	{
          		module: "newsfeed",
          		position: "bottom_bar",
          		config: {
          			feeds: [
          				{
          					title: "New York Times",
          					url: "http://www.nytimes.com/services/xml/rss/nyt/HomePage.xml"
          				}
          			],
          			showSourceTitle: true,
          			showPublishDate: true
          		}
          	},
          ]
          

          };

          /*************** DO NOT EDIT THE LINE BELOW ***************/
          if (typeof module !== “undefined”) {module.exports = config;}

          1 Reply Last reply Reply Quote 0
          • B Offline
            bokow
            last edited by

            Never mind got the Dad Jokes working by moving where the text was displayed to a blank area of the screen

            S 1 Reply Last reply Reply Quote 0
            • S Offline
              sdetweil @bokow
              last edited by sdetweil

              @bokow could u edit your post with the config and add three backticks (shifted left of 1 key) on the 1st line, then config start on line 2, and 3 backticks on the last line by themselves…

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              1 Reply Last reply Reply Quote 1
              • B Offline
                bokow
                last edited by

                All I had to do was place the location of the jokes to an unoccupied part of the screen. It now works as advertised but t his raises a new problem with the calendar module. The calendar shows nothing, even holidays. I guess my question is where does this app take the calendar info from??

                S 1 Reply Last reply Reply Quote 0
                • S Offline
                  sdetweil @bokow
                  last edited by

                  @bokow this app??

                  from your google calendar or apple ical…

                  u have to configure the url to the calendar

                  Sam

                  How to add modules

                  learning how to use browser developers window for css changes

                  1 Reply Last reply Reply Quote 0
                  • B Offline
                    bokow
                    last edited by

                    what url and to what app?

                    bheplerB 1 Reply Last reply Reply Quote 0
                    • bheplerB Offline
                      bhepler Module Developer @bokow
                      last edited by

                      @bokow - First, please go edit your post with the config.js content and add the three back-ticks before the first line of the code and after the last line. That’s the markdown feature I was talking about.

                      Second, you will have to find the URL for your calendar in .ics format. Depending on what provider you are using, there will be different instructions on how to find it. A search for “export my calendar to ICS format” will get you pointed in the right direction.

                      1 Reply Last reply Reply Quote 0
                      • 1
                      • 2
                      • 1 / 2
                      • First post
                        Last post
                      Enjoying MagicMirror? Please consider a donation!
                      MagicMirror created by Michael Teeuw.
                      Forum managed by Sam, technical setup by Karsten.
                      This forum is using NodeBB as its core | Contributors
                      Contact | Privacy Policy