Skip to content
master
Switch branches/tags
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
src
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Simple OAuth App

Simple oauth app in Node.js. It's completely based on Async Tree Pattern. The main point of this app is to show that it's possible to create oauth app in the declarative way.

Stack of technologies

Node.js, MongoDB, @cuties, JWT (basic implementation, using @cuties/jwt).

Why this example is cool

  1. It's based on @cuties, so you can write your asyncronous code in the declarative way (without callbacks, Promises, and async/await abstractions).
  2. You can see how authentication can be implemented with only simple external https requests.
  3. You can see how JWT works (@cuties/jwt).

You can use docker to run the app

docker-compose build
docker-compose up -d mongo
docker-compose up app

You can open it on http://localhost:8000/

Installation without docker

First of all you need to install MongoDB on your machine.

Then type following commands:

git clone git@github.com:Guseyn/simple-oauth-app.git
npm install
npm run build
npm start

You can open it on http://localhost:8000/

Model

User: {
  _id,
  name,
  email,
  password,
  description,
  signupDate
}

OAuth types

  1. Basic: email and password
  2. Google OAuth
  3. GitHub OAuth

All these types are synchronized, so you can everytime choose different way to sign in your profile.

Screenshots

Demo

IMAGE ALT TEXT HERE

About

Simple OAuth App in Node.js (pure declarative approach).

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published