Here's my random quotes generator, advices needed

Here's my random quotes generator, advices needed
0.0 0

#1

Hi all !

Here’s my quote generator on codepen.
What do you think ?

I’ve tried to keep the code as simple as possible, yet I haven’t managed to use the get-quote function (declared at the beginning of $(document).ready) in getJSON and $("#new_quote").clickpart to avoid code repetition.
Do you have any tip about this ?


#2

Some of the quotes are missing authors, there is just a blank “—” underneath.


#3

Yep, some quotes just don’t authors, it’s from the quote file. There’s nothing I can do about it :slight_smile:


#4

You can check if author is empty and then display something like ‘unknown author’.