New to node, .net background.I am used to having MS dictate how my project should be structure, node is giving me too much rope to hang myself with!I have a very basic app, which offers local user authentication, registration, and forgot password.Before i branch and start building out the guts of my app, i could really use some coaching on how to improve the structure of my code.I feel like its fairly clean, but certain there is room to improve before i move o n and star amplifying bad habits.my project is here: http://ift.tt/1Q881hi would appreciate any feedback. particular points i am not confident in are as follows:1) I tried to keep my server.js file as minimal as possible by modularizing my code into config(db connection), models(User), middleware(passport initialization), and routes.2) i dont think im going about handling routes well, as my routes grow this single file will become unwieldy... suggestions?3) is initializing my passport in a module a wierd thing to do?4) is my user model structured well? I expect to build other models using this as a template.any advice appreciated!
Submitted February 20, 2016 at 10:19PM by HoneyBadger08
No comments:
Post a Comment