Code Monkey home page Code Monkey logo

node-js-api's Introduction

NodeJS + ExpressJS

Ruben Anaya

  • Date of development: 27/11/2023

API

  • FakerJS was used to generate dinamyc data with the specified columns: name, date, favorite food, favorite movie and status
  • Each time the API outputs a result, it logs in the console the active user only
  • If a sort value if provided as a query stirng in the url endpoint, then a message in the console displays by which field the results are sorted
  • To use the api, you need to do a GET request to the following endpoints:
    API_URL:PORT/users --> Will display all users without sort
    API_URL:PORT/users?sortBy='status,name' --> Will display all users sorted by the specified fields

Installation

  • nvm use (if you are using Node Version Manager) or at least node version 20.0.0
  • create a .env file in the root project folder structure with the following variables:
    PORT and place the api port that the api will use to expose it's endpoint
  • yarn install
  • yarn start

Tech stack

  • NodeJS
  • ExpressJS
  • FakerJS

node-js-api's People

Contributors

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