Git Product home page Git Product logo

programmeren-4-shareameal-jaronvw's Introduction

Share-a-meal-api

Backend-API for the share-a-meal assignment.

A small and lightweight API made with Node.js and Express.


Features

  • Create, update, read and delete meals and users
  • JWT authentication
  • Input validation
  • persistence with MySQL

Development

This project requires a MySQL Database to run

The Repository can be cloned from Github, after that run the following command

npm install 

This installs the required dependencies for local development. After that create a .env in the root of the project and store the following enviroment variables. Further explanation about .env files can be found here.

DB_HOST DB_PORT DB_USER DB_DATABASE DB_PASSWORD SECRET_JWT_KEY TEST_TOKEN

This makes sure the server makes use of your local configuration and prevents sensitive data from being published.


Database structure

The Project contains the file share-a-meal.sql, this can be used to configure the database, after this is done and the database works the project is ready to be run.

Starting the server

npm start 

For developing, this command is recommended

npm run dev 

this restarts the server every time a file is saved.


Testing

npm test

This runs the tests made with Mocha and Chai.

programmeren-4-shareameal-jaronvw's People

Contributors

jaronvw avatar rschellius 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.