Coder Social home page Coder Social logo

nestgoose's Introduction

Nest Logo

Instagram clone made using Nestjs + Mikro-orm codebase(backend) containing real world examples (CRUD, auth, advanced patterns, etc)

CI

Getting started

Clone this repo. Edit the env file and pass in your credentials

Installation

Install dependencies

 yarn

Database

Mikro Orm

The example codebase uses MikroORM with a Postgres database.

Copy MikroORM config example file and adjust the connection settings and other settings(jwt,redism,mail,etc) respectively on sample env file

Start local Postgres server and run NODE_ENV=dev yarn orm:up to apply migrations

Now you can start the application witt `NODE_ENV=dev yarn start.

Note: Env files are kept in env folder. The config validation allows 4 environment ['dev', 'prod', 'test','stage']. The env file name should be of format .env.[environment] Ex. (.env.test). The env to use should be provided while running any script as NODE_ENV=dev npm run dev


NPM scripts

  • yarn start - Start application
  • yarn start:watch - Start application in watch mode
  • yarn test - run Jest test runner
  • yarn start:prod - Build application

Start application

  • yarn start
  • Test api by browsing to http://localhost:[port]/v1/user
  • View automatically generated swagger api docs by browsing to http://localhost:[port]/docs

Authentication

This applications uses JSON Web Token (JWT) to handle authentication. The token is passed with each request using the Authorization header with Token scheme. The JWT authentication middleware handles the validation and authentication of the token.

Todos

FRONTEND

nestgoose's People

Contributors

rubiin avatar dependabot[bot] 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.