Coder Social home page Coder Social logo

bookmarks-api's Introduction

Bookmarks api

This is a simple API created with the purpose of learning NestJS.

The API consist of 2 main modules: one for user management (using JWT for authentication) and one for bookmarks management.

Requirements

  • Node.js, there is a .nvmrc file in the root of the project, you can use nvm (with nvm use command) to install the correct version of node
  • NestJS, you can follow steps at https://docs.nestjs.com/first-steps

Technology overview

This is a list of the main technologies/libraries used in this project:

  • NestJS with TypeScript
  • Prisma, an ORM for TypeScript
  • Docker to start PostgreSQL databases
  • Jest for testing, there is an e2e test for all the endpoints
  • PactumJS for API testing

Useful commands

Initial

  • npm install -> to install all the dependencies
  • npm run db:dev:restart -> to start database and apply Prisma migrations
  • npm run start:dev -> to start the application in development mode

NestJS

  • nest g module <name> -> to generate a module
  • nest g service <name> --no-spec -> to generate a service without spec file

Prisma

  • npx prisma init -> to initialize prisma
  • npx prisma migrate dev -> runs prisma migrations
  • npx prisma studio -> runs prisma studio (allows to see the database)
  • npx dotenv -e .env.test prisma studio -> runs prisma studio with specific env variables

Credits

This code was created following https://www.youtube.com/watch?v=GHTA143_b-s

bookmarks-api's People

Contributors

dependabot[bot] avatar albertocortina avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.