Skip to content

MagicMirror² module to display the daily or random web comic of XKCD.

License

Notifications You must be signed in to change notification settings

jupadin/MMM-XKCD

Repository files navigation

MMM-XKCD

License

This module is an extention for the MagicMirror.

The module is based on the work of Blastitt with simplified configuration options and cleaner user interface.

Installation

Open a terminal session, navigate to your MagicMirror's modules folder and execute git clone https://github.com/jupadin/MMM-XKCD.git, such that a new folder called MMM-XKCD will be created.

Activate the module by adding it to the config.js file of the MagicMirror as shown below.

The table below that lists all possible configuration options.

You also have to install all dependencies inside the module directory by calling

npm install --only=prod

Using the module

    modules: [
        {
            module: 'MMM-XKCD',
            position: 'top_right',
            config: {
                header: "xkcd",
                updateInterval: 10 * 60 * 60 * 1000,
                grayScale: false,
                invertColors: false,
                limitComicWidth: 400,
                limitComicHeight: 0,
                randomComic: false,
                alwaysRandom: false,
                showTitle: true,
            }
        }
    ]

Configuration options

The following configuration options can be set and/or changed:

Option Type Default Description
header string xkcd Header, which will be displayed
updateInterval int 36000000 Update interval of comic [milliseconds] (10 hours)
grayScale bool false Desaturate colors of the comic to grayscale
invertedColors bool false Invert colors of the comic to create a darker feeling
limitComicWidth int 400 Limit the maximum width of the comic (0 implies to use the maximal width of the comic)
limitComicHeight int 0 Limit the maximum height of the comic (0 implies to use the maximal height of the comic)
randomComic bool false Display a random comic, where no new comic is available.
alwaysRandom bool false If you always want to see a random comic, even on days where a new comic is available. Note: Only effective if randomComic is set to true.
showTitle bool true Display the title of the comic with given header

About

MagicMirror² module to display the daily or random web comic of XKCD.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published