Read the statement by Michael Teeuw here.
Config.js not working
-
Hi guys,
I am able to get my magicmirror working with the standard config.js settings preinstalled, but when i then add aditional modules, the config file stops working.
I have tried everything to get it running, but it fails to load.
Could someone please review my config file and advise where i have gone wrong.All help appreciated
/* Magic Mirror Config file
*- By Michael Teeuw http://michaelteeuw.nl
- MIT Licensed.
*/
var config = {
port: 8080,
ipWhitelist: [“127.0.0.1”, “::ffff:127.0.0.1”, “::1”], // Set [] to allow all IP addresses.language: "en", timeFormat: 24, units: "metric", modules: [ { module: "alert", }, { module: "updatenotification", position: "top_bar" }, { module: "clock", position: "top_left" }, { module: "calendar", header: "UK Holidays", position: "top_left", config: { calendars: [ { symbol: "calendar-check-o ", url: "https://www.calendarlabs.com/ical-calendar/ics/75/UK_Holidays.ics" } ] } }, { module: "compliments", position: "lower_third" }, { module: "currentweather", position: "top_right", config: { location: "Mansfield", locationID: "2643097", //ID from http://www.openweathermap.org/help/city_list.txt appid: "1ff19eb375630ae2d015b49428d7cbec" } }, { module: "weatherforecast", position: "top_right", header: "Weather Forecast", config: { location: "Mansfield", locationID: "2643097", //ID from http://www.openweathermap.org/help/city_list.txt appid: "1ff19eb375630ae2d015b49428d7cbec" } }, { module: "newsfeed", position: "bottom_bar", config: { feeds: [ { title: "Sky News", url: "http://feed.skynews.com/feeds/rss/uk.xml" } ], showSourceTitle: true, showPublishDate: true } }, { module: 'MMM-Traffic', position: 'bottom_right', classes: 'dimmed medium', //optional, default is 'bright medium', only applies to commute info not route_name config: { api_key: 'your_apikey_here', mode: 'driving', origin: '4 Pennsylvania Plaza, New York, NY 10001', destination: '1 MetLife Stadium Dr, East Rutherford, NJ 07073', mon_destination: '116th St & Broadway, New York, NY 10027', fri_destination: '1 E 161st St, Bronx, NY 10451', arrival_time: '0800', //optional, but needs to be in 24 hour time if used. route_name: 'Home to Work', changeColor: true showGreen: false, limitYellow: 5, //Greater than 5% of journey time due to traffic limitRed: 20, //Greater than 20% of journey time due to traffic traffic_model: 'pessimistic' interval: 120000 //2 minutes }, ]
};
/*************** DO NOT EDIT THE LINE BELOW ***************/
if (typeof module !== “undefined”) {module.exports = config;} -
you’re missing a }
{ module: 'MMM-Traffic', position: 'bottom_right', classes: 'dimmed medium', config: { api_key: 'your_apikey_here', mode: 'driving', origin: '4 Pennsylvania Plaza, New York, NY 10001', destination: '1 MetLife Stadium Dr, East Rutherford, NJ 07073', mon_destination: '116th St & Broadway, New York, NY 10027', fri_destination: '1 E 161st St, Bronx, NY 10451', arrival_time: '0800', //optional, but needs to be in 24 hour time if used. route_name: 'Home to Work', changeColor: true showGreen: false, limitYellow: 5, //Greater than 5% of journey time due to traffic limitRed: 20, //Greater than 20% of journey time due to traffic traffic_model: 'pessimistic' interval: 120000 //2 minutes } },
-
@nonamero thank you for your reply. I have edited the file as advised, but i still get the dread: Please Create a Config File.
I have tried deleting the input and typing all manually, but to no avail.
-
@dandrea30
there are two commas missing{ module: 'MMM-Traffic', position: 'bottom_right', classes: 'dimmed medium', //optional, default is 'bright medium', only applies to commute info not route_name config: { api_key: 'your_apikey_here', mode: 'driving', origin: '4 Pennsylvania Plaza, New York, NY 10001', destination: '1 MetLife Stadium Dr, East Rutherford, NJ 07073', mon_destination: '116th St & Broadway, New York, NY 10027', fri_destination: '1 E 161st St, Bronx, NY 10451', arrival_time: '0800', //optional, but needs to be in 24 hour time if used. route_name: 'Home to Work', changeColor: true, showGreen: false, limitYellow: 5, //Greater than 5% of journey time due to traffic limitRed: 20, //Greater than 20% of journey time due to traffic traffic_model: 'pessimistic', interval: 120000 //2 minutes } },