Socket
Socket
Sign inDemoInstall

functional.js

Package Overview
Dependencies
0
Maintainers
1
Versions
84
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 0.7.1 to 0.7.3

2

bower.json

@@ -6,3 +6,3 @@ {

"homepage": "http://functionaljs.com",
"version": "0.7.1",
"version": "0.7.3",
"keywords": [

@@ -9,0 +9,0 @@ "functional",

@@ -6,3 +6,3 @@ {

"homepage": "http://functionaljs.com",
"version": "0.7.1",
"version": "0.7.3",
"keywords": [

@@ -9,0 +9,0 @@ "functional",

/*!
functional.js (v0.7.1)
functional.js (v0.7.3)
(c) Lee Crossley <leee@hotmail.co.uk> (http://ilee.co.uk/)
*/
var fjs=function(){"use strict";var n={},r="hardReturn;",t=function(r){if(n.isString(r)){var t=r.match(/(.*)\s*[=-]>\s*(.*)/);t.shift();var u=t.shift().replace(/^\s*|\s(?=\s)|\s*$|,/g,"").split(" "),e=t.shift();return t=(/\s*return\s+/.test(e)?"":"return ")+e,u.push(t),Function.apply({},u)}},u=function(n){return n.length>0?[].slice.call(n,0):[]};n.isFunction=function(n){return!!(n&&n.constructor&&n.call&&n.apply)},n.isObject=function(r){return n.isFunction(r)||!!r&&"object"==typeof r},n.isArray=function(n){return"[object Array]"===Object.prototype.toString.call(n)};var e=function(r){if(!n.isFunction(r)&&(r=t(r),!n.isFunction(r)))throw"fjs Error: Invalid function";return r};return n.curry=function(r){return r=e(r),function t(){var e=u(arguments);if(e.length===r.length)return r.apply(null,e);if(e.length>r.length){var c=r.apply(null,e);return n.fold(r,c,e.slice(r.length))}return function(){var n=u(arguments);return t.apply(null,e.concat(n))}}},n.each=n.curry(function(t,u){if(t=e(t),n.exists(u)&&n.isArray(u))for(var c=0;c<u.length;c+=1)if(t.call(null,u[c],c)===r)return}),n.map=n.curry(function(r,t){r=e(r);var u=[];return n.each(function(){u.push(r.apply(null,arguments))},t),u}),n.fold=n.foldl=n.curry(function(r,t,u){return r=e(r),n.each(function(n,u){t=r.call(null,t,n,u)},u),t}),n.reduce=n.reducel=n.foldll=n.curry(function(r,t){r=e(r);var u=t[0];return t.shift(),n.fold(r,u,t)}),n.clone=function(r){var t=[];return n.each(function(n){t.push(n)},r),t},n.first=n.head=n.take=n.curry(function(t,u){t=e(t);var c;return n.each(function(n){return t.call(null,n)?(c=n,r):void 0},u),c}),n.rest=n.tail=n.drop=n.curry(function(r,t){var u=n.select(r,t);return u.shift(),u}),n.last=n.curry(function(r,t){var u=n.clone(t);return n.first(r,u.reverse())}),n.every=n.all=n.curry(function(t,u){t=e(t);var c=!0;return n.each(function(n){return t.call(null,n)?void 0:(c=!1,r)},u),c}),n.any=n.contains=n.curry(function(t,u){t=e(t);var c=!1;return n.each(function(n){return t.call(null,n)?(c=!0,r):void 0},u),c}),n.select=n.filter=n.curry(function(r,t){r=e(r);var u=[];return n.each(function(n){r.call(null,n)&&u.push(n)},t),u}),n.best=n.curry(function(r,t){r=e(r);var u=function(n,t){return r.call(this,n,t)?n:t};return n.reduce(u,t)}),n["while"]=n.curry(function(t,u){t=e(t);var c=[];return n.each(function(n){return t.call(null,n)?void c.push(n):r},u),c}),n.compose=function(r){var t=n.any(function(r){return!n.isFunction(r)});if(r=u(arguments).reverse(),t(r))throw"fjs Error: Invalid function to compose";return function(){var t=arguments,u=n.each(function(n){t=[n.apply(null,t)]});return u(r),t[0]}},n.partition=n.curry(function(r,t){r=e(r);var u=[],c=[];return n.each(function(n){(r.call(null,n)?u:c).push(n)},t),[u,c]}),n.group=n.curry(function(r,t){r=e(r);var u,c={};return n.each(function(n){u=r.call(null,n),c[u]=c[u]||[],c[u].push(n)},t),c}),n.shuffle=function(r){var t,u;return n.each(function(n,e){t=Math.floor(Math.random()*(e+1)),u=r[e],r[e]=r[t],r[t]=u},r),r},n.toArray=function(r){return n.map(function(n){return[n,r[n]]},Object.keys(r))},n.apply=n.curry(function(r,t){var u=[];return n.isArray(r)&&(u=[].slice.call(r,1),r=r[0]),n.map(function(n){return n[r].apply(n,u)},t)}),n.assign=n.extend=n.curry(function(r,t){return n.each(function(n){t[n]=r[n]},Object.keys(r)),t}),n.prop=function(n){return function(r){return r[n]}},n.pluck=n.curry(function(r,t){return n.map(n.prop(r),t)}),n.nub=n.unique=n.distinct=n.curry(function(r,t){var u=t.length>0?[t[0]]:[];return n.each(function(t){n.any(n.curry(r)(t),u)||(u[u.length]=t)},t),u}),n.exists=function(n){return null!=n},n.truthy=function(r){return n.exists(r)&&r!==!1},n.falsy=function(r){return!n.truthy(r)},n.each(function(r){n["is"+r]=function(n){return Object.prototype.toString.call(n)==="[object "+r+"]"}},["Arguments","Date","Number","RegExp","String"]),n}();"undefined"!=typeof exports&&("undefined"!=typeof module&&module.exports&&(exports=module.exports=fjs),exports.fjs=fjs);

@@ -6,3 +6,3 @@ {

"homepage": "http://functionaljs.com",
"version": "0.7.1",
"version": "0.7.3",
"main": "functional.min.js",

@@ -33,3 +33,3 @@ "keywords": [

"type": "git",
"url": "git@github.com:leecrossley/functional-js.git"
"url": "git@github.com:functionaljs/functional-js.git"
},

@@ -36,0 +36,0 @@ "engines": {

@@ -1,2 +0,2 @@

# functional.js (fjs) [![Build Status](https://travis-ci.org/leecrossley/functional-js.png?branch=master)](https://travis-ci.org/leecrossley/functional-js) [![npm version](https://badge.fury.io/js/functional.js.png)](https://npmjs.org/package/functional.js) [![devDependency Status](https://david-dm.org/leecrossley/functional-js/dev-status.png)](https://david-dm.org/leecrossley/functional-js#info=devDependencies)
# functional.js (fjs) [![Build Status](https://travis-ci.org/functionaljs/functional-js.png?branch=master)](https://travis-ci.org/functionaljs/functional-js) [![npm version](https://badge.fury.io/js/functional.js.png)](https://npmjs.org/package/functional.js) [![devDependency Status](https://david-dm.org/functionaljs/functional-js/dev-status.png)](https://david-dm.org/functionaljs/functional-js#info=devDependencies)

@@ -3,0 +3,0 @@ <img align="right" src="http://functionaljs.com/css/images/logo@2x.png">

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc