Skip to content

GiovanniDw/party-finder

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

74 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Party Finder

With Party Finder you can find gamers with the same intrests as you!


This repo is a project based on the following course at HvA CMD

Project Tech is a first stepping stone for you to become a well-rounded web developer (or a designer with knowledge of how things are made). You'll build a dynamic prototype of a web application. This project continues where earlier courses left off with topics such as HTML, CSS, JS, research, design, and project management.

The research of this project will be documented in the Wiki

Features

  • Register/Login.
  • Add Profile info.
  • Search for games using the IGDB api.
  • Add a game to your profile.
  • Like/Dislike Profiles.

Contents

Run locally

Before you can run this project locally nodejs & npm must be installed

Clone this project & Install the dependencies:

  $ git clone https://github.com/GiovanniDw/party-finder.git  
  $ cd party-finder
  $ npm install

Before the app can be started, we need to create a .env file in the root folder of the app. This file must have some env variables specified below.

The .env file could look something like this:

MONGO_DB=mongodb+srv://<username>:<password>@<context>-xxxxxx.mongodb.net/test
DB_NAME=< The name of your mongoDB >
PORT="XXXX"
SESSION_SECRED='xxxxxxx'
API_KEY='xxxxxxxxx'

Start the app:

$ npm run start

Start the app with nodemon:

$ npm run nmStart

Code Overview

Dependencies

  • expressjs - Fast, unopinionated, minimalist web framework for node.
    • express-session
    • multer - Multer is a node.js middleware for handling multipart/form-data, which is primarily used for uploading files.
    • body-parser - Parse incoming request bodies in a middleware before your handlers, available under the req.body property.
    • cookie-parser - Parse Cookie header and populate req.cookies with an object keyed by the cookie names.
  • ejs - Embedded JavaScript templates.
  • dotenv - Dotenv is a zero-dependency module that loads environment variables from a .env file into process.env.
  • mongoose - Mongoose is a MongoDB object modeling tool designed to work in an asynchronous environment. Mongoose supports both promises and callbacks.
  • passport - Passport is Express-compatible authentication middleware for Node.js.
    • passport-local - The local authentication strategy authenticates users using a username and password.
    • connect-flash - show any authentication error messages in our login form.
    • bcrypt - bcrypt is the hashing algorithm to protect stored credentials.
  • apicalypse - A simple client for creating Apicalypse queries.

devDependencies

  • nodemon - nodemon is a tool that helps develop node.js based applications by automatically restarting the node application when file changes in the directory are detected.
  • node-sass - node-sass allows you to natively compile .scss files to css at incredible speed and automatically via a connect middleware.
  • ejs-lint - Linter/Syntax Checker for EJS Templates.

Folder Structure

  .
  ├── app/
  │   ├── controllers/            # Contains the controllers for the routes.
  │   │   └── *.js
  │   ├── helpers/
  │   │   └── **/*.js
  │   ├── models/                 # Contains the Schema defenitions for Mongoose models
  │   │   └── *.js
  │   └── views/                  # Contains ejs files that will be compiled to html by expressjs
  │       └── **/*.ejs
  ├── config/                     # Configuration will be managed in this folder
  │   ├── middleware/             # Contains middleware functions.
  │   │   └── *.js
  │   ├── routes/                 # Contains the app's routes.
  │   │   └── **/*.js
  │   └── passport.js             # Contains configuration for passport.
  ├── static/                     # Contains static files that will be rendered in the root folder
  │   ├── css/
  │   │   └── main.css
  │   ├── images/
  │   │   └── **/*
  │   ├── js/
  │   │   └── **/*.js
  │   ├── sass/
  │   │   └── **/*.sass
  │   ├── splashscreens/
  │   ├── uploads/
  │   │   └── **/*
  │   ├── favicon.ico
  │   └── manifest.json
  ├── .editorconfig
  ├── .gitignore
  ├── LICENCE
  ├── package.json
  ├── Procfile
  ├── README.md
  └── server.js                    # The entry point to the application.

Resources

Licence

All code in this repository is provided under the MIT License