text: const express = require('express');
  const port = 3002;
  const app = express();
  const bodyParser = require('body-parser');
  const routes = require('./routing/routes');
  
  // Use Node.js body parsing middleware
  app.use(bodyParser.json());
  app.use(bodyParser.urlencoded({
      extended: true,
  }));
  app.use(function (req, res, next) {
      console.log("Adding CORS headers");
      res.header("Access-Control-Allow-Origin", "*"); // update to match the domain you will make the request from
      res.header("Access-Control-Allow-Headers", "Origin, X-Requested-With, Content-Type, Accept");
      next();
  });
  
  //REST API Routes
  routes(app);
  
  
  // Start the server
  const server = app.listen(port, (error) => {
      if (error) return console.log(`Error: ${error}`);
  
      console.log(`Server listening on port ${server.address().port}`);
  });