How (not) to create a singleton in Node.js
Iain Collins
4406

https://medium.com/@iaincollins/how-not-to-create-a-singleton-in-node-js-bd7fde5361f5
Hello,

Thanks for the post !

Another smart solution is a to use a dependency injection framework,

I coded Di-Ninja for this

https://github.com/di-ninja/di-ninja

It’s full featured and is the only one, as I know, that implement the smart Composition-Root design pattern

It’s working on server and browser

One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.