• 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.

Complete Options List for config.js

Scheduled Pinned Locked Moved Troubleshooting
13 Posts 6 Posters 3.1k Views 5 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
    broberg Project Sponsor @nimbus78
    last edited by Mar 19, 2019, 4:21 PM

    @nimbus78

    The issues you state isn’t an issue with what variables the different modules have, the issue you have can easily be remedied with a introduction class to javascript. (But I understand, not everyone will have the will or energy to get a grip on it just to get a config file right).

    And I also understand that some modules aren’t really made for all to use, giving the lack of information for some.
    Using the Readme file from the stock modules is good basis for a readme-template to apply to the modules one makes, and maybe it’s here we should put in more effort to clean things up, but again most 3rd-party modules are made of other users so the support (if any) is thereafter.

    And there is a logic to the use of Quotation marks, commas and brackets.

    Strings of text needs Quotation marks “Something something text string”
    Numbers need no Quotation marks 1234
    Boolean values, True or False, should not have quotation marks even though they are text.

    Commas are use after each “line” unless the “line” is the last one. It’s easier to grasp if you put everything on one row.
    modules: [{module: “alert”},{module: “updatenotification”, position: “top_bar”},{module: “clock”, position: “top_left”} ]

    N 1 Reply Last reply Mar 19, 2019, 4:46 PM Reply Quote 0
    • N Offline
      nimbus78 @sdetweil
      last edited by Mar 19, 2019, 4:40 PM

      @sdetweil I didn’t know about this tool. I will definitely check it out. Thank you.

      1 Reply Last reply Reply Quote 0
      • N Offline
        nimbus78 @Guest
        last edited by Mar 19, 2019, 4:42 PM

        @Sean if I understand this correctly, I can simply copy the text from my config.js file, paste it into the js validator, and it will show me any mistakes that are in my setup?

        ? P 2 Replies Last reply Mar 19, 2019, 4:50 PM Reply Quote 0
        • N Offline
          nimbus78 @broberg
          last edited by Mar 19, 2019, 4:46 PM

          @broberg that is the simplest, most comprehensive explanation I’ve seen so far. That really helps to wrap my head around this. That explanation should be included in the readme file for the MagicMirror. Thank you.

          1 Reply Last reply Reply Quote 0
          • ? Offline
            A Former User @nimbus78
            last edited by Mar 19, 2019, 4:50 PM

            @nimbus78 yes

            1 Reply Last reply Reply Quote 0
            • P Offline
              pingywon @nimbus78
              last edited by Mar 24, 2019, 5:08 PM

              @nimbus78 yes. Assuming you are in Windows… download notepad++. It’s free. Once you have it open go to the plug in manager and search for java or jscript plug ins. I can not think of the one that I really like at the moment but you can then copy your config to your windows box. Hit one button and it will line everything up nice and clean jscript format. It will make looking at your config a lot easier. From there it will also tell you if you are forgetting a comma or curly bracket as you add modules to your config.

              Use winscp to copy the config to/from your pi.

              Also. Once you have a good workin config and you wanna play with a new module. Make a back up first so that if it doesn’t work out or you are frustrated you can “restore the back up”

              On the pi command line to create a back up.

              Navigate to the die with your config:

              cp config.filename backupfile.name

              cp is the copy command and it works as “from” and then “to”

              If you ever need to restore:

              cp backupfile.name config.filename.

              Reload and you are safely back where you started before screwing with your config.

              Hopefully some of this helps you.

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