Read the statement by Michael Teeuw here.
Hi very beginners question here.
-
Hi all.
I’m very new to magic mirror.
So I managed to get it running on the basic layout and thought I’d try my first module and with the simple dad jokes one.
I have the folder showing in the modules folders and then 8 went to the main config.js file to enter the bit of code.var config = { modules: [ { module: 'MMM-Dad-Jokes', position: 'bottom_left', // Or wherever you want config: { updateInterval: 60000, fadeSpeed: 4000 } } ] }But it’s not working I’m getting a error when loading saying about not having a valid config file.
I think I’m copying and pasting it in the wrong part or I’m copying too much of it.
Could someone break it down for me with what I do with the above code on a fresh config file as I’m not actually sure where to do the curser click when I click paste is it after the last closed bracket ?
Cheers -
@steveuk it looks good… try running the checker
npm run check:configfrom the MM folder
u need all that upper stuff too, right?
address: "", // 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: 8086, ipWhitelist: [], // 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: 12, units: "imperial", -
@sdetweil
Hi thanks the reply yeah I have all the upper parts as normal.
I deleted the file and tried again with a different module following YouTube and got it to work.
I noticed some of these instructions on the module installation come with extra bits of text I don’t need to copy and paste in, I think I’m confusing myself with when I need the { } and },
But like I say I did get a module to show up but in the config I put “bottom_right” but it shows on the top left.
Thanks again. -
@steveuk a module entry will have at LEAST this
{ module: 'module_name', position: 'some_region_name', config: { // module specific info } },see here for the region definitions
https://forum.magicmirror.builders/topic/286/regions -
@steveuk said in Hi very beginners question here.:
Could someone break it down for me with what I do with the above code on a fresh config file as I’m not actually sure where to do the curser click when I click paste is it after the last closed bracket ?
It should look like this. Your entry was missing a comma after the last curly bracket.
{ module: 'MMM-Dad-Jokes', position: 'bottom_left', // Or wherever you want config: { updateInterval: 60000, fadeSpeed: 4000 } },This will help you understand the format of a config entry.
https://forum.magicmirror.builders/topic/4231/how-to-add-modules-for-absolute-beginners
-
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login