3 Issues in creating Random Quote Machine

I have used React and bootstrap to make this Random Quote Machine.
This is the link to my code.
https://codepen.io/agrawalparul2/pen/BaQjPBg

I have 3 issues I am unable to solve:-

First :- I have used font awesomeness to get twitter icon but I don’t know where I am going wrong as it doesn’t display twitter icon.

Second:- I am not able to set the background color of entire page. I tried specifying the height of 100% in CSS, but that doesn’t work.

Third:- When the page loads for first time it doesn’t display the quote only after pressing the new quote button it starts displaying quotes. I tried adding addeventlistener under componentwillmount to handle this. But it doesn’t work either.

Please let me know inputs on how can I fix these.
Thanks in Advance.

  1. Your classes are wrong. Where do you have the classes from? Search for font awesome twitter and you will find the correct classes.

  2. 100% in relation to the parent element. The parent (#root) has no height. You can use 100vh to make one of both elements fill the whole screen height.

  3. You have spelling errors on your lifecycle method names.

Thanks so much. I could fix all.

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.