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.

JavaScript Express Basics Using Templates with Express Express’s Response.render Method

Cant get '/card' to run in browser

my index.pug file is working when I get on the landing page in browser, but when I try to navigate to the /card page it says cannot GET. please help

const express = require('express');

const app = express();

app.set('view engine', 'pug');

app.get('/', (req, res) => { res.render('index'); });

app.get('/cards', (req, res) => { res.locals.prompt = "Who is buried in Tut's Tomb?", hint: "Think about who's tomb it is" res.render('card'); });

app.listen(3030, () => { console.log('The application is running on localhost:3030!') });

heres my /card file

doctype html html(lang="en") head title Flash Cards body header h1 Flash Cards section#content h2= prompt p i Hint #{hint} footer p This will be the start of some real coding!