목록Personal DB/Unclassified record (50)
Silver Library (Archived)
Note. M = Data V = How does the data look like C = function which looks for the data So, why MVC all of sudden? To separate both 'URL' and 'function' for the sake of my mental health. By separating the URL sections to (1) another file with (2) another name of folder, let the folder name 'controller', and let that controller be the place to importing site for 'routers (folder)'. What this mean is..
To share the code contents of specific file (e.g. let app.js to share the code with init.js) Need to add 'export default app;' to the origin source. So, it can literally export so! 'export default app;' is the code. Then import it as follows: 'import app from "./app";' Now, here is all about 'routes'. How to use router? Router is the file which contains many route. 1. To let it work as router (d..
What is 'middleware' express? Something there goes connection until it goes finishes(executed). Between the user and last response. Something is in in that middle of it. In express, every function can become middleware. const betweenHome = () => console.log("I'm between"); If you turn on the page you input that const variable, now you can see the loading circle is spinning forever. That's how mi..
[Note: from now on, this section may link to express] What is babel? babel is a JS compiler. Basically, a tool to convert JS thing to backend like. babeljs.io/docs/en/ Babel · The compiler for next generation JavaScript The compiler for next generation JavaScript babeljs.io What is babel/preset-env? A Good source to refer this is here. velog.io/@pop8682/%EB%B2%88%EC%97%AD-%EC%99%9C-babel-preset%..