• Recent
  • Tags
  • Unsolved
  • Solved
  • MagicMirror² Repository
  • Documentation
  • 3rd-Party-Modules
  • Donate
  • Discord
  • Register
  • Login
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.

After upgrade: Clock module getting error: "Can't find variable: moment"

Scheduled Pinned Locked Moved Troubleshooting
3 Posts 2 Posters 2.6k Views 2 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.
  • T Offline
    tkotz8621
    last edited by Apr 3, 2017, 4:13 PM

    I initially updated MagicMirror2 to V2.1.1 through git pull but then started getting blank screen running serveronly and so I reinstalled entire MagicMirror2 and modules. Started serveronly again and getting blank screen again. When I look in system log file, I’m getting the error:
    Message: console message: http://localhost:8080/modules/default/clock//clock.js @49: ReferenceError: Can’t find variable: moment
    Message: console message: http://localhost:8080/modules/default/clock//clock.js @77: ReferenceError: Can’t find variable: moment
    Did I miss installing a dependency?
    I’m running MagicMirror on Pi Zero, Raspian Jessie

    S 1 Reply Last reply Apr 3, 2017, 7:23 PM Reply Quote 0
    • S Offline
      strawberry 3.141 Project Sponsor Module Developer @tkotz8621
      last edited by Apr 3, 2017, 7:23 PM

      @tkotz8621 you have to run npm install in the MagicMirror directory, which will itself call npm install in the vendor directory for moment.js

      Please create a github issue if you need help, so I can keep track

      1 Reply Last reply Reply Quote 0
      • T Offline
        tkotz8621
        last edited by Apr 3, 2017, 9:18 PM

        Thanks for the quick response strawberry 3.141. I thought I ran ‘npm install’ but I ran it as you suggested and now clock is working. Thanks again.

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