My aim today was to dynamically update the city name on the web app with the city from the search results. The city name was not been updated yesterday after a get request because i was using country
to fetch class country in my query selector instead of .country
. I kept running into a "country is null error."
Code before:
const country = document.querySelector('country');
country.textContent = data.name
Code after:
const country = document.querySelector('.country');
country.textContent = data.country.name
😅 I'm literally so angry at that .
for taking all my time 😂
Day 57
Top comments (2)
these stuffs happen all da time :D dont get mad and keep it up ;)
I better get used to it. I will keep up. 😊