This project is a backend application built with ExpressJS and PostgreSQL, providing a RESTful API for managing articles, comments, and user interactions such as voting and filtering.
The application is deployed and hosted on a DigitalOcean Droplet, making it accessible online and ensuring that I have hands-on experience with cloud-based deployments.
- Serve article data via RESTful API
- CRUD operations for articles and comments
- Filter articles by topics and article sorting
- Pagination for article and comment lists
- ExpressJS: Web framework for Node.js
- PostgreSQL: Relational database to store articles and comments
- Jest: Testing framework for unit and integration tests (TDD approach)
- Supertest: HTTP assertion library used for testing API endpoints
- Husky: Git hook tool that ensures code quality by running pre-commit or pre-push hooks to enforce linting, testing, and other checks before changes are pushed to the repository
- Node.js (v22.6.0 or above)
- PostgreSQL database running locally or remotely
- Clone the repository:
git clone https://github.com/digital-cowboy-91/nc-backend-project.git cd nc-frontend-project npm i
- Create
.env.development
, 'env.test' (and 'env.production') file with following environmental variables:PG_DATABASE=nc_news # or nc_news_test, or link to remote PG
- See the database
npm run seed
- Serve application
npm run start
- Run test
npm run test
This portfolio project was created as part of a Digital Skills Bootcamp in Software Engineering provided by Northcoders