Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community!
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.Start your free trial
Attach the following view to my app with the route of /teachers.
def teachers(): return 'We have lots of teachers!'
im stuck anyone?
Adding a route above a function requires a decorator of @app.route
then inside the parenthesis you need to specify what the route is in the parenthesis.
@app.route('/') def index(): return "This is my home page!"
I suggest reviewing this video :) First Steps
flasking can be tough and the is a lot you have to pay attention too. this code here is what it should look like. Happy coding!
return "We have lots of teachers"