Sancus.js better api for ES6 promises
Summary
Sancus provides similar to Scala api for promises/futures, for those of us who think that es6 promise api is rather counterintuitive. Sancus doesn't provide any new functionality just makes api better, if not awesome. This micro-library named after roman god of oaths and truth - Sancus.
Usage
Basic example:
;const deferred = ;deferredpromise;deferred;
Async example:
// Function connects to mongo, and returns promise.; { // Create instance of deferred. const deferred = ; // Perform connection. MongoClient; // Return reference to promise. return deferredpromise;} // Usage example: ;