Skip to content Skip to sidebar Skip to footer
Showing posts with the label Commonjs

Commonjs Modules - Exporting A Function That Returns A Function With Arguments

In this rendr - sessions example, there's an express middleware module... module.exports = func… Read more Commonjs Modules - Exporting A Function That Returns A Function With Arguments

What Is The Benefit Of A 'promise' Abstraction In Commonjs?

I'm reading this article and the section on the promise abstraction seems a little overly compl… Read more What Is The Benefit Of A 'promise' Abstraction In Commonjs?

Jest - Mock A Constant Property From A Module For A Specific Test

So, I'm attempting to do something which on the surface should be very simple... I have some co… Read more Jest - Mock A Constant Property From A Module For A Specific Test

Are Asynchronous Modules Always Asynchronous?

When multiple JavaScript modules are define()'d using AMD and concatenated into a single file, … Read more Are Asynchronous Modules Always Asynchronous?