Welcome to the Treehouse Community

The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.


getWeather() not defined

Hi everyone,

I am building a weather app as a second portfolio project. It is pretty straight forward:

  • shows weather on user location (works fine)
  • shows weather based on city search (doesn't work at all, console says: getWeather() not defined but it is defined)

Can somebody just tell me what am doing wrong please? Thank you.

github app.js link: https://github.com/Geronimo1992/weather-app-milestone-project/blob/master/assets/js/app.js

1 Answer

20,469 Points

There is a typo on line 41. Don't know if there i anything else wrong too though.

thanks but it it was something else. It's working now :), not sure why though... still figuring that out.