⚠️ ⚠️ ⚠️ This repo has been archived. The unofficial XKCD API is unavailable. Backing web app is no longer available on Heroku.⚠️ ⚠️ ⚠️
Load random comic strips from http://xkcd.com/
Using npm:
⇒ npm install xkcd-get
Using bower:
⇒ bower install xkcd-get
Load the javascript file, xkcd.js
, into your page.
<script src="xkcd.js"></script>
Add such a div
element:
<div class="xkcd-img"></div>
Any element with the class xkcd-refresh
will be targeted when adding a listener to listen for click. The xkcd comics will be replaced once such an element is clicked.
<a href="#" class="xkcd-refresh"></a>
Thanks to:
- Randall Munroe for the xkcd comic strips.
- Hemanth for hosting the web app serving urls to random comic strips from xkcd.
- You for enjoying comics.
The MIT License (MIT)
Copyright (c) 2015-2016 GochoMugo (www.gmugo.in)