NodeJS API-Part 5 / Model/Router/Controller structure

explanation of our model/router/controller structure

CREATING YOUR FOLDERS/FILES

- api
- controllers
- dojos.js
- models
- dojos.js
- routes
- dojos.js

ADD THE CODE TO THE FILES

const dojosRoutes = require("./api/routes/dojos");...app.use("/dojos", dojosRoutes);

CONCLUSION

explanation of our model/router/controller structure

--

--

--

Flutter and Delphi Developer at Green. Teacher at SoonClass

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

Software Resilience: 7 must-have factors for healing from the unexpected

Testing React Frontends at TrialSpark

Setting up eslint, prettier, airbnb-base and typescript

Create Interactive WebGL-powered Buttons

Amazon s3 bucket image upload using node.js

How To Set-Up an API Fetch Request in Rails

Augmented Reality — Unity and Vuforia, let’s get busy…

GCD Sorting of an Array.

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
Soon Sam Santos

Soon Sam Santos

Flutter and Delphi Developer at Green. Teacher at SoonClass

More from Medium

Push Strapi to Heroku Using Github Repository

Containerize React.js Application With Node.js

How To Test a NodeJS Module using Mocha and Assert

Simple NestJs App With MongoDB