You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Had a code roast, here are some of the suggetions I want to work on next....
Modularize Node methods, request and response shouldn't be passed all the way into functions, separate functional code from the REST API
In the package.json, don't use latest for versions.
To simplify version management: npm list (npm list -g for global installed). using tilde (e.g. "~1.01") allows updates for buig fixes but not major versions.
Externalize npm module versions: One of the people from MeetMe described briefly how to put the version numbers in a file independent of the package.json, I need to reach out and get a better explanation from her
Look into npm shrinkwrap for managing package dependencies
Look into npm outdated
IN routes.js and in the server for the ENyo project, replace the multi lines for the public GET with fstream.pipe(res)
In routes.js, instead of passing all the instantiated singletons, create a module which exports an instance that can then be pulled into where it's needed instead of passing via signature
The text was updated successfully, but these errors were encountered:
Last night I looked at modularizing the methods. The comment was: Avoid passing the request/response objects all the way down the chain.
The problem I'm having is each call is a nested chain of callbacks and promises. So breaking out the functionality into methods doesn't work since almost everything is asynchronous. Putting them in promise chains will create many extra methods, And I still have to pass around the response object. So not sure how to tackle this yet.
Had a code roast, here are some of the suggetions I want to work on next....
The text was updated successfully, but these errors were encountered: