All Questions
4 questions
2
votes
2
answers
154
views
How should I store time stamps so that it's easily accessible and won't take too much space
tldr at the bottom if you don't want to read all this! :)
First of all the db I'm using is MongoDB! So I've been building a fun project and all has been well but I hit a small problem. Effectively, ...
5
votes
3
answers
4k
views
Node.js error handling through each layer
I am looking for a way to handle errors in a Node.js application without getting lots of log entries for the same error event, one from each each affected layer.
This might actually apply to any ...
4
votes
1
answer
177
views
Node.js callbacks and this - how it should be solved?
Every JavaScript programmer is familiar with this "problem" (it can be considered as a feature, depending on various conditions) - this is lately binded:
let foo = {
bar(){return this;}
};
let ...
2
votes
1
answer
2k
views
Should I prefer classes or singletons in JavaScript/Node?
This question applies especially to Node.js, but also to JavaScript in general.
I started working on a simple web app in Node.js. I'm relatively new to Node and JavaScript, and come mainly from C# ...