Code Monkey home page Code Monkey logo

backendnodejsmongodb's Introduction

Table of Contents

  1. Backend NodeJS + MongoDB
  2. Tugas: Create Endpoint CRUD Dosen
  3. TDLR;
  4. Proof of Concept

Backend NodeJS + MongoDB

Paduan Download dan Install Dependensi yang dibbutuhkan dengan cara dibawah

git clone https://github.com/ahmdsk/BackendNodeJSMongoDB
cd BackendNodeJSMongoDB
npm install
nodemon server.js

Setelah itu local server akan berjalan di port 3000

http://localhost:3000

Tugas: Create Endpoint CRUD Dosen

TDLR;

Sebelumnya kita telah selesai membuat endpoint untuk operasi CRUD Mahasiswa dengan NodeJS dan MongoDB sebagai database nya. untuk selanjutnya ada test pemahaman tentang materi sebelumnya untuk berfokus pada materi restful api backend dengan NodeJS dan MongoDB. test pemahaman atau tugas nya membuat endpoint untuk CRUD Dosen, rekan-rekan dapat mengikuti kode sebelumnya untuk mengerjakan.

Proof of Concept

Untuk isi object dari collection dosen sebagai berikut:

  • nama
  • matkul_diampu
  • alamat

silahkan dibuat model dari data object diatas pada folder models/ kemudian buat file Dosen.js jadi pada file models/ terdapat 2 file yaitu Mahasiswa.js dan Dosen.js

Untuk ketentuan endpoint restful api dosen sebagai berikut:

HTTP METHOD PATH URL
GET /dosen
POST /dosen
PUT /dosen/edit/:id
DELETE /dosen/delete/:id

jika tugas sudah selesai, susun semua endpoint dalam satu collection Postman atau Upload ke github pribadi (pilih salah satu, atau keduanya lebih baik). kemudian share/invite collection postman atau repository github nya ke email [email protected]

backendnodejsmongodb's People

Contributors

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