MMM-Screencast
MMM-Screencast copied to clipboard
Config.js issues
when loading up MagicMirror I get this error: `WARNING! Could not validate config file. Starting with default configuration. Please correct syntax errors at or above this line: /home/pi/MagicMirror/config/config.js:45 var config = { ^^^
SyntaxError: Unexpected token var
at new Script (vm.js:74:7)
at createScript (vm.js:246:10)
at Object.runInThisContext (vm.js:298:10)
at Module._compile (internal/modules/cjs/loader.js:678:28)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:722:10)
at Module.load (internal/modules/cjs/loader.js:620:32)
at tryModuleLoad (internal/modules/cjs/loader.js:559:12)
at Function.Module._load (internal/modules/cjs/loader.js:551:3)
at Module.require (internal/modules/cjs/loader.js:658:17)
at require (internal/modules/cjs/helpers.js:20:18)
`
Here is my config.js layout;
` modules: [ { module: "clock", position: "top_left" }, { module: "calendar", header: "US Holidays", position: "top_left", config: { calendars: [ { symbol: "calendar-check", url: "webcal://www.calendarlabs.com/ical-calendar/ics/76/US_Holidays.ics" } ] } }, var config = { modules: [ { module: 'MMM-Screencast', position: 'bottom_right', // This position is for a hidden
and not the screencast window config: { position: 'bottomRight', height: 300, width: 500, } } ] }, {
module: 'MMM-Weather-Now',
position: 'top_left',
config: {
api_key: '5b41e47985d14fcf803187ff9e2c9951',
lat: 39.4495560,
lon: -75.7163207,
units: 'I',
lang: 'en',
interval: 900000
}
},`
Hey @Zpider23 can you post you're entire config file in this issue with the api_key
s removed?
The issues seems to be something with your formatting and it looks like GitHub is picking up on some of the markdown inconsistencies. So if you can just paste the file in here?
Also as a side note, you should keep your api keys private, so you might want to invalidate the ones you already posted in here, so others can't use your either paid account or abuse your free one.
Finally, sorry bout the delay there was another issue that I was trying to fix and you'd actually need to grab the new version of MMM-Screencast to make sure that you don't get this error either. refer to this comment: https://github.com/kevinatown/MMM-Screencast/issues/41#issuecomment-550010303
Thanks!