Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

mixinable

Package Overview
Dependencies
Maintainers
1
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mixinable - npm Package Compare versions

Comparing version 1.1.1 to 1.2.0

10

CHANGELOG.md

@@ -5,2 +5,12 @@ # Change Log

<a name="1.2.0"></a>
# [1.2.0](https://github.com/dmbch/mixinable/compare/v1.1.1...v1.2.0) (2017-11-27)
### Features
* add purely async strategy exports ([487f62d](https://github.com/dmbch/mixinable/commit/487f62d))
<a name="1.1.1"></a>

@@ -7,0 +17,0 @@ ## [1.1.1](https://github.com/dmbch/mixinable/compare/v1.1.0...v1.1.1) (2017-11-26)

@@ -70,2 +70,17 @@ 'use strict';

exports.async = {
override: function () {
return Promise.resolve(exports.override.apply(null, arguments));
},
parallel: function () {
return Promise.resolve(exports.parallel.apply(null, arguments));
},
pipe: function () {
return Promise.resolve(exports.pipe.apply(null, arguments));
},
compose: function () {
return Promise.resolve(exports.compose.apply(null, arguments));
}
};
exports.clone = function clone (instance) {

@@ -72,0 +87,0 @@ var args = argsToArray(arguments).slice(1);

2

package.json
{
"name": "mixinable",
"version": "1.1.1",
"version": "1.2.0",
"description": "Functional JavaScript Mixin Utility",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -6,2 +6,4 @@ 'use strict';

var async = mixinable.async;
test('exports test', function (t) {

@@ -13,2 +15,7 @@ t.equal(typeof mixinable, 'function', 'main export is a function');

t.equal(typeof mixinable.pipe, 'function', 'pipe is a function');
t.equal(typeof mixinable.compose, 'function', 'compose is a function');
t.equal(typeof async.override, 'function', 'async.override is a function');
t.equal(typeof async.parallel, 'function', 'async.parallel is a function');
t.equal(typeof async.pipe, 'function', 'async.pipe is a function');
t.equal(typeof async.compose, 'function', 'async.compose is a function');
t.end();

@@ -461,1 +468,20 @@ });

});
test('async helper test', function (t) {
var instance = mixinable({
foo: async.override,
bar: async.parallel,
baz: async.pipe,
qux: async.compose
})({
foo: function () {},
bar: function () {},
baz: function () {},
qux: function () {}
})();
t.ok(instance.foo() instanceof Promise, 'override result is a promise');
t.ok(instance.bar() instanceof Promise, 'parallel result is a promise');
t.ok(instance.baz() instanceof Promise, 'pipe result is a promise');
t.ok(instance.qux() instanceof Promise, 'compose result is a promise');
t.end();
});
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc