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.

    code issue

    Scheduled Pinned Locked Moved Troubleshooting
    6 Posts 3 Posters 1.2k Views 3 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.
    • C Offline
      cade72
      last edited by yawns

      i have no clue what is wrong with my code, I am very new and had to restart my pi because i was testing stuff. I put all my changes back in at once(which I now realized was dumb lol) and now it says config error. i tried to use this
      node tests/configs/check_configs.js but this didnt seem to work. here is the code, thanks in advance for the help!

              language: "en",
              timeFormat: 12,
              units: "imperial",
      
              modules: [
                      {
                              module: "alert",
                      },
                      {
                              module: "updatenotification",
                              position: "top_bar"
                      },
                      {
                              module: "clock",
                              position: "top_left"
                              config: {
                                      displaySeconds: false,
                      }
                      },
                      {
                              module: "",
                              header: "US Holidays",
                              position: "top_left",
                              config: {
                                      calendars: [
                                              {
                                                      symbol: "calendar-check",
                                                      url: "webcal://www.calendarlabs.com/templates/ical/US-Holidays.ics"
                                              }
                                      ]
                              }
                      },
                      {
                              module: "",
                              position: "lower_third"
                      },
       {
                              module: "currentweather",
                              position: "top_right",
                              config: {
                                      onlyTemp: true,
                                      roundTemp: true,
                                      location: "Shawnee",
                                      locationID: "4279247",  //ID from http://bulk.openweathermap.org/sample/; unzip the gz file and find your city
                                      appid: "6272b5d982857a7f9dc98abe37f263f4"
                              }
                      },
                      {
                              module: "weatherforecast",
                              position: "top_right",
                              header: "Weather Forecast",
                              config: {
                                      roundTemp: true,
                                      location: "Shawnee",
                                      locationID: "4279247",  //ID from https://openweathermap.org/city
                                      appid: "6272b5d982857a7f9dc98abe37f263f4"
                              }
                      },
                      {
                              module: "",
                              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;}
      
      C ? 2 Replies Last reply Reply Quote 0
      • C Offline
        cade72 @cade72
        last edited by

        @cade72

        not sure if this helps but here is what comes up when i put in node tests/configs/check_configs.js

        ~/MagicMirror $ node tests/configs/check_configs.js
        internal/modules/cjs/loader.js:550
        throw err;
        ^

        Error: Cannot find module ‘/home/pi/MagicMirror/tests/configs/check_configs.js’
        at Function.Module._resolveFilename (internal/modules/cjs/loader.js:548:15)
        at Function.Module._load (internal/modules/cjs/loader.js:475:25)
        at Function.Module.runMain (internal/modules/cjs/loader.js:695:10)
        at startup (internal/bootstrap/node.js:201:19)
        at bootstrapNodeJSCore (internal/bootstrap/node.js:516:3)

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

          @cade72 said in code issue:

          > node tests/configs/check_configs.js
          

          one too many ‘s’…

          node tests/configs/check_config.js
          

          my error…

          Sam

          How to add modules

          learning how to use browser developers window for css changes

          C 1 Reply Last reply Reply Quote 0
          • ? Offline
            A Former User @cade72
            last edited by

            @cade72 after position of clock, comma is missed.

            C 1 Reply Last reply Reply Quote 1
            • C Offline
              cade72 @sdetweil
              last edited by

              @sdetweil ohhh all good, I was super confused why it wasnt working. Thanks!

              1 Reply Last reply Reply Quote 0
              • C Offline
                cade72 @Guest
                last edited by

                @sean commas always seem to win vs me lol. Thanks!

                1 Reply Last reply Reply Quote 0
                • 1 / 1
                • 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