I’m wokring on this project: https://codesandbox.io/s/news-reader-app-9pnig
It basically collect news article from a News API. I have a div with an id of “news-articles”. This div contains all the news articles which are populated dynamically. I have given a background color to that div but it is not reflecting. I have given the div a height of 100%.
Am I missing something?
#news-articles is a Flex container/column so it should grow as required. You don’t need the
height the constraint.
Not 100% sure here, but my guess is that the HTML/CSS loads first before the JS gets the data and your container is fixed to 100% of an empty container. You could remove it or use a
I’d mark that as the solution @pragyes31.
Thanks @pjonp! I should of thought of it. It worked.