diff --git a/content/assets/scripts/quote.coffee b/content/assets/scripts/quote.coffee deleted file mode 100644 index 2da96ef..0000000 --- a/content/assets/scripts/quote.coffee +++ /dev/null @@ -1,4 +0,0 @@ -$ -> - $.getJSON './quotes.json', (data) -> - quote = data[Math.floor(Math.random()*data.length)] - $('#quote').append("

#{quote.title}

#{quote.description}

") diff --git a/content/assets/scripts/quote.js b/content/assets/scripts/quote.js new file mode 100644 index 0000000..593e159 --- /dev/null +++ b/content/assets/scripts/quote.js @@ -0,0 +1,7 @@ +$(function() { + return $.getJSON('./quotes.json', function(data) { + var quote; + quote = data[Math.floor(Math.random() * data.length)]; + return $('#quote').append("

" + quote.title + "

" + quote.description + "

"); + }); +});