Build a Personal Profile App - Certification Project

Tell us what’s happening:

I’m currently working through the “Build a Personal Profile App” and can get all of the tests to pass except for the first step requiring me to install express (which I do have installed).

I’m unsure if it’s a bug or not but using npm install express does actually install it and runs the server with no issues but won’t register it in tests.

If anyone has a work around to get the certification to accept I have express installed that would be great as this is currently blocking my progression :slight_smile:

Your code so far

import express from 'express';
const app = express();
const PORT = 3000;


app.get('/', (req, res) => {
  res.send("Welcome to Camper Bot's homepage!");
});

app.get('/hobbies', (req, res) => {
  res.send("I cycle, go boating, and play guitar.");
});

app.get('/skills', (req, res) => {
  res.send("JavaScript, Node.js, and Express.js!");
});

app.get('/api/profile', (req, res) => {
  res.json({
    name: "Camper Bot",
    hobbies: ['cycling', 'boating', 'guitar'],
    skills: ['JavaScript', 'Node.js', 'Express.js']
  });
});

app.listen(PORT, () => {
  console.log(`Server is running on port ${PORT}`);
});

Lesson URL https://www.freecodecamp.org/learn/back-end-development-and-apis-v9/lab-personal-profile-app/lab-personal-profile-app

Welcome to the forum @luke.e

Try restarting the server.

Happy coding

Hi Teller,

Thanks for getting back to me, I figured it out!

I needed to run npm init before installing everything in order to have the package.json files etc. for the tests to validate the express install.

It was not mentioned in the tasks but I know meant to be standard when setting these up!