functionfoundry
Advanced tools
Comparing version 0.11.2 to 0.12.0
{ | ||
"name": "functionfoundry", | ||
"version": "0.11.2", | ||
"version": "0.12.0", | ||
"description": "Pure function JavaScript library", | ||
@@ -5,0 +5,0 @@ "main": "fn/_index.js", |
[](https://circleci.com/gh/WebsiteHQ) | ||
FunctionFoundry is a JavaScript function library for `Node.js` and module bundles like [webpack](https://webpack.github.io/) and [browserify](http://browserify.org/). | ||
FunctionFoundry is JavaScript function library without side effects. | ||
It is the foundation for [formula](https://github.com/WebsiteHQ/formula). | ||
It is for [formula](https://github.com/WebsiteHQ/formula). | ||
@@ -7,0 +7,0 @@ ## Install |
@@ -6,3 +6,4 @@ import branch from '../src/branch'; | ||
test('branch', function(t) { | ||
t.plan(12); | ||
t.plan(21); | ||
t.equal( typeof branch, 'function' ); | ||
@@ -22,2 +23,14 @@ t.equal( branch( false, 1), undefined ); | ||
// check for truthy and falsy values | ||
t.equal( branch( 6, 1, 2), 1 ); | ||
t.equal( branch( {}, 1, 2), 1 ); | ||
t.equal( branch( 1, 1, 2), 1 ); | ||
t.equal( branch( [], 1, 2), 1 ); | ||
t.equal( branch( 0, 1, 2), 2 ); | ||
t.equal( branch( '', 1, 2), 2 ); | ||
t.equal( branch( null, 1, 2), 2 ); | ||
t.equal( branch( undefined, 1, 2), 2 ); | ||
t.equal( branch( NaN, 1, 2), 2 ); | ||
}); |
Sorry, the diff of this file is not supported yet
Major refactor
Supply chain riskPackage has recently undergone a major refactor. It may be unstable or indicate significant internal changes. Use caution when updating to versions that include significant changes.
Found 1 instance in 1 package
Filesystem access
Supply chain riskAccesses the file system, and could potentially read sensitive data.
Found 1 instance in 1 package
0
59721
150
1832
1