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

Is there a Difference between these ???

Scheduled Pinned Locked Moved Unsolved Troubleshooting
12 Posts 5 Posters 2.2k 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.
  • P Offline
    plainbroke
    last edited by plainbroke Jul 19, 2023, 11:08 PM Jul 19, 2023, 11:01 PM

    Does config.js see a difference between these?
    {
    ipAddress: “192.168.178.31”,
    name: “QNAP1”,
    icon: “database”,
    colorStateOnline: “green”,
    colorStateOffline: “red”,
    },

    { ipAddress: “192.168.178.31”, name: “QNAP1”, icon: database", colorStateOnline: “green”, colorStateOffline: “red” },

    I only ask because I can not get the color State’s to work.

    Slow learner. But trying anyways.

    W B E 3 Replies Last reply Jul 20, 2023, 3:44 AM Reply Quote 0
    • W Offline
      wishmaster270 Module Developer @plainbroke
      last edited by Jul 20, 2023, 3:44 AM

      @plainbroke Hi,

      please use the code ticks to post code.

      Yes there is a difference, you missed a " before database in the second one.

      1 Reply Last reply Reply Quote 0
      • B Offline
        BKeyport Module Developer @plainbroke
        last edited by Jul 20, 2023, 7:25 PM

        @plainbroke To expand on @wishmaster270 comment - To post code, please use the button
        that looks like this: 1967f487-8ada-4dad-af09-500c3dfb3cb4-image.png

        that button puts this ``` into your text, allowing you to get code posted like this to make it readable:

        {
        ipAddress: “192.168.178.31”,
        name: “QNAP1”,
        icon: “database”,
        colorStateOnline: “green”,
        colorStateOffline: “red”,
        },
        

        The "E" in "Javascript" stands for "Easy"

        S 1 Reply Last reply Jul 20, 2023, 7:54 PM Reply Quote 0
        • S Offline
          sdetweil @BKeyport
          last edited by sdetweil Jul 20, 2023, 8:11 PM Jul 20, 2023, 7:54 PM

          @BKeyport however

          if u copy/paste from outside a code block backtics

          the bad quotes(curved/slanted) are copied, as in your example

          and will not be corrected, and will cause problems in config.js

          Sam

          How to add modules

          learning how to use browser developers window for css changes

          B 1 Reply Last reply Jul 20, 2023, 9:11 PM Reply Quote 0
          • B Offline
            BKeyport Module Developer @sdetweil
            last edited by Jul 20, 2023, 9:11 PM

            @sdetweil (that wasn’t a copy. It was escaped. backslash ` )

            The "E" in "Javascript" stands for "Easy"

            S 1 Reply Last reply Jul 21, 2023, 12:19 AM Reply Quote 0
            • S Offline
              sdetweil @BKeyport
              last edited by Jul 21, 2023, 12:19 AM

              @BKeyport your post has the bad quotes
              that’s all I was saying, even tho in code block

              Sam

              How to add modules

              learning how to use browser developers window for css changes

              B 1 Reply Last reply Jul 21, 2023, 4:27 AM Reply Quote 0
              • B Offline
                BKeyport Module Developer @sdetweil
                last edited by Jul 21, 2023, 4:27 AM

                @sdetweil oh, I C&P’d that. :)

                The "E" in "Javascript" stands for "Easy"

                S 1 Reply Last reply Jul 21, 2023, 11:33 AM Reply Quote 0
                • S Offline
                  sdetweil @BKeyport
                  last edited by Jul 21, 2023, 11:33 AM

                  @BKeyport yes, that was my point

                  Sam

                  How to add modules

                  learning how to use browser developers window for css changes

                  P 1 Reply Last reply Jul 23, 2023, 2:09 AM Reply Quote 0
                  • P Offline
                    plainbroke @sdetweil
                    last edited by Jul 23, 2023, 2:09 AM

                    Ok, I get it I did not post it correctly.
                    What I am trying to get at does it matter if the line is one line of text or does it need to be several lines to make it read correctly in MM?

                    Slow learner. But trying anyways.

                    S 1 Reply Last reply Jul 23, 2023, 3:59 AM Reply Quote 0
                    • S Offline
                      sdetweil @plainbroke
                      last edited by sdetweil Jul 23, 2023, 4:01 AM Jul 23, 2023, 3:59 AM

                      @plainbroke the 3backtics of the code block must be on a separate line. start and end

                      Sam

                      How to add modules

                      learning how to use browser developers window for css changes

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