GithubHelp home page GithubHelp logo

coding-challenge's Introduction

Coding challenge

This project is a simple MERN aplication composed by two projects:

  • back: a Express server which serves a simple CRUD API.
  • front: a React app consuming the API.

The backend

The backend is an application bootstrapped from Express Generator which connects to a MongoDB database and performs CRUD operations.

  • You can check the API documentation in /api.
  • You can also check the database connection status in /health.

Technologies used

  • Express: NodeJS web framework.
  • Mongoose: ODM for MongoDB.
  • Swagger UI: API's documentation.

The frontend

The front is bootstrapped from Create React App. It is a simple SPA that lists all the users and allow the following actions:

  • Create.
  • Edit.
  • Delete.

Technologies used

  • React: JS frontend library.
  • Redux: for state management.
  • Material UI: React's components library that follows Google's Material Design Guidelines.
  • Moment: JS library for date manipulation.
  • Axios: promised based http client.

Installation

After you downloaded the files, you need to perform the following actions:

Run the back

You must have Nodemon installed globally in order to run the back in dev mode.

In the back folder:

  • Run npm installin order to install al required packages.

  • Create a .env file with the following values:

    HOST=server_hostname

    PORT=server_port

    DB=database_connection_string

    TESTDB=database_connection_string (*it will be a temporary database were tests will be done)

    DBHOST=database_host

    DBPORT=database_port

  • Run npm run dev to run it in development mode.

  • You can also run some basic tests with npm run test.

Run the front

In the front folder:

  • Run npm install
  • Create a .env.development file with the value REACT_APP_API=local_back_hostname
  • Create a .env.production file with the value REACT_APP_API=remote_back_hostname
  • Run npm start

Give it a try!

You can see the project in action here: https://fullstack-coding-challenge.herokuapp.com/.

coding-challenge's People

Contributors

rubenvillarnet 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.