-
Notifications
You must be signed in to change notification settings - Fork 3
Tech Debt
-
With each new feature database queries are increasing, so there should be a mechanism to build/manage the queries.
-
Sqlite3 is file based database system, if we host it on the heroku it won’t be able to persist the data for longer duration, so we need a persistent way to store data.
-
some functions in the frontend are getting repeated, instead make the generic functions in order to avoid the repetition.
-
isValidRequest is being used by many requests instead we can make it a middleware. Adding the frequently used handler as a middleware.
-
All the handlers are stored in a single file instead we can separate the user handlers. So that it will be easy to manage the handlers.
-
While testing the database, we are using javascript objects to mock db functions. In some places we are using sinon for mocking. We can make mocking consistent by using sinon everywhere.
-
Instead of using available pug template we are creating html again in the frontend. We can use pug template to render that html.
-
We are not handling the database errors in the handlers. Right now there is no way in the frontend to know whether database operation is failing
POSTIT