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

tcomb

Package Overview
Dependencies
Maintainers
1
Versions
74
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

tcomb - npm Package Compare versions

Comparing version 0.3.0 to 0.3.1

4

CHANGELOG.md

@@ -0,1 +1,5 @@

# v0.3.1
- Make `Struct.extend` accept array of extensions
# v0.3.0

@@ -2,0 +6,0 @@

64

index.js

@@ -131,64 +131,2 @@ (function (root, factory) {

/*
function namespace(path, module) {
if (!Arr.is(path)) {
path = path.split('.');
}
var lastIndex = path.length - 1;
var init = {};
var isModule = arguments.length > 1;
path.reduce(function reducer(acc, x, i) {
return (acc[x] = isModule && i === lastIndex ? module : {});
}, init);
return init;
}
function update(instance, spec, value) {
if (!spec) { return instance; }
// handle update(instance, path, value)
if (Str.is(spec)) {
return update(instance, namespace(spec, {$set: value}));
}
value = shallowCopy(instance);
for (var k in spec) {
if (spec.hasOwnProperty(k)) {
var s = spec[k];
switch (k) {
case '$apply' :
return s(instance);
case '$concat' :
// TODO optimize
return value.concat(s);
case '$set' :
return spec[k];
case '$splice' :
value.splice.apply(value, s);
return value;
case '$swap' :
var el = value[s.to];
value[s.to] = value[s.from];
value[s.from] = el;
return value;
case '$remove' :
return update._;
case '$prepend' :
// TODO optimize
return [].concat(s).concat(value);
}
value[k] = update(value[k], s);
if (value[k] === update._) {
delete value[k];
}
}
}
return value;
}
update._ = {};
*/
function shallowCopy(x) {

@@ -402,3 +340,3 @@ return Arr.is(x) ? x.concat() : Obj.is(x) ? mixin({}, x) : x;

Struct.extend = function extendStruct(newProps, name) {
return struct(mixin(mixin({}, props), newProps), name);
return struct([props].concat(newProps).reduce(mixin, {}), name);
};

@@ -405,0 +343,0 @@

{
"name": "tcomb",
"version": "0.3.0",
"version": "0.3.1",
"description": "Pragmatic runtime type checking for JavaScript",

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

@@ -281,2 +281,5 @@ > "Si vis pacem, para bellum" (Vegetius 5th century)

var p = new Point3D({x: 1, y: 2, z: 3});
// `props` can be an array of new props
var Point4D = Point.extend([{z: Num}, {time: Num}], 'Point4D');
```

@@ -283,0 +286,0 @@

@@ -1,6 +0,6 @@

// tcomb 0.2.1
// tcomb 0.3.1
// https://github.com/gcanti/tcomb
// (c) 2014 Giulio Canti <giulio.canti@gmail.com>
// tcomb may be freely distributed under the MIT license.
!function(a,b){"use strict";"function"==typeof define&&define.amd?define([],b):"object"==typeof exports?module.exports=b():a.t=b()}(this,function(){"use strict";function a(a){throw w=!0,new Error(a)}function b(a){x.onFail(a)}function c(a){if(a!==!0){var c=y.call(arguments,1),d=c[0]?f.apply(null,c):"assert failed";b(d)}}function d(a,b,d){if(A.is(b))return a;for(var e in b)b.hasOwnProperty(e)&&(d||c(!a.hasOwnProperty(e),"cannot overwrite property %s",e),a[e]=b[e]);return a}function e(){return Array.prototype.reduce.call(arguments,function(a,b){return d(a,b,!0)},{})}function f(){function a(a,e){if("%%"===a)return"%";if(d>=c)return a;var g=f.formatters[e];return g?g(b[d++]):a}var b=y.call(arguments),c=b.length,d=1,e=b[0],g=e.replace(/%([a-z%])/g,a);return c>d&&(g+=" "+b.slice(d).join(" ")),g}function g(a,b){return"function"==typeof b?f("Func",b.name):b}function h(a){return c(K.is(a),"Invalid argument `type` of value `%j` supplied to `getName()`, expected a type.",a),a.meta.name}function i(a){return c(K.is(a),"Invalid argument `type` of value `%j` supplied to `geKind()`, expected a type.",a),a.meta.kind}function j(a,b){c(!(a instanceof b),"Operator `new` is forbidden for `%s`",h(b))}function k(a){return E.is(a)?a.concat():F.is(a)?d({},a):a}function l(a,b){c(!A.is(a)),c(F.is(b));var d=k(a);for(var e in b)if(b.hasOwnProperty(e)){if(l.commands.hasOwnProperty(e))return c(1===Object.keys(b).length),l.commands[e](b[e],d);d[e]=l(d[e],b[e])}return d}function m(a,b){function d(e){return j(this,d),c(b(e),"Invalid `%s` supplied to `%s`",e,a),e}return c("string"==typeof a,"Invalid argument `name` supplied to `irriducible()`"),c("function"==typeof b,"Invalid argument `is` supplied to `irriducible()`"),d.meta={kind:"irriducible",name:a},d.is=b,d}function n(a,b){function e(d,f){if(e.is(d))return d;if(c(F.is(d),"Invalid `%s` supplied to `%s`, expected an `Obj`",d,b),!(this instanceof e))return new e(d,f);for(var g in a)if(a.hasOwnProperty(g)){var h=a[g],i=d[g];this[g]=h(i,f)}f!==!0&&Object.freeze(this)}return c(u(B,K).is(a),"Invalid argument `props` supplied to `struct()`"),c(p(B).is(b),"Invalid argument `name` supplied to `struct()`"),b=b||"struct",e.meta={kind:"struct",props:a,name:b},e.is=function(a){return a instanceof e},e.update=function(a,b,c){return new e(l(a,b,c))},e.extend=function(b,c){return n(d(d({},a),b),c)},e}function o(a,b){function d(a,e){j(this,d),c(G.is(d.dispatch),"unimplemented %s.dispatch()",b);var f=d.dispatch(a);return c(K.is(f),"%s.dispatch() returns no type",b),f(a,e)}c(t(K).is(a),"Invalid argument `types` supplied to `union()`");var e=a.length;return c(e>=2,"Invalid argument `types` supplied to `union()`"),c(p(B).is(b),"Invalid argument `name` supplied to `union()`"),b=b||f("union([%s])",a.map(h).join(", ")),d.meta={kind:"union",types:a,name:b},d.is=function(b){return a.some(function(a){return a.is(b)})},d.dispatch=function(b){for(var c=0,d=a.length;d>c;c++)if(a[c].is(b))return a[c]},d}function p(a,b){function d(b,c){return j(this,d),A.is(b)?null:a(b,c)}return c(K.is(a),"Invalid argument `type` supplied to `maybe()`"),"maybe"===i(a)?a:(c(A.is(b)||B.is(b),"Invalid argument `name` supplied to `maybe()`"),b=b||f("maybe(%s)",h(a)),d.meta={kind:"maybe",type:a,name:b},d.is=function(b){return A.is(b)||a.is(b)},d)}function q(a,b){function d(a){return j(this,d),c(d.is(a),"Invalid `%s` supplied to `%s`, expected one of %j",a,b,e),a}c(F.is(a),"Invalid argument `map` supplied to `enums()`"),c(p(B).is(b),"Invalid argument `name` supplied to `enums()`"),b=b||"enums";var e=Object.keys(a);return d.meta={kind:"enums",map:a,name:b},d.is=function(b){return B.is(b)&&a.hasOwnProperty(b)},d}function r(a,b){function d(f,g){if(c(E.is(f)&&f.length===e,"Invalid `%s` supplied to `%s`, expected an `Arr` of length `%s`",f,b,e),d.isTuple(f))return f;for(var h=[],i=0;e>i;i++){var j=a[i],k=f[i];h.push(j(k,g))}return g!==!0&&Object.freeze(h),h}c(t(K).is(a),"Invalid argument `types` supplied to `tuple()`");var e=a.length;return c(p(B).is(b),"Invalid argument `name` supplied to `tuple()`"),b=b||f("tuple([%s])",a.map(h).join(", ")),d.meta={kind:"tuple",types:a,length:e,name:b},d.isTuple=function(b){return a.every(function(a,c){return a.is(b[c])})},d.is=function(a){return E.is(a)&&a.length===e&&d.isTuple(a)},d.update=function(a,b,c){return d(l(a,b,c))},d}function s(a,b,d){function e(f,h){j(this,e);var i=a(f,h);return c(b(i),"Invalid `%s` supplied to `%s`, %s",f,d,g),i}c(K.is(a),"Invalid argument `type` supplied to `subtype()`"),c(G.is(b),"Invalid argument `predicate` supplied to `subtype()`"),c(p(B).is(d),"Invalid argument `name` supplied to `subtype()`"),d=d||f("subtype(%s)",h(a));var g=b.__doc__||f("insert a valid value for %s",b.name||"the subtype");return e.meta={kind:"subtype",type:a,predicate:b,name:d},e.is=function(c){return a.is(c)&&b(c)},e.update=function(a,b,c){return e(l(a,b,c))},e}function t(a,b){function d(e,f){if(c(E.is(e),"Invalid `%s` supplied to `%s`, expected an `Arr`",e,b),d.isList(e))return e;for(var g=[],h=0,i=e.length;i>h;h++){var j=e[h];g.push(a(j,f))}return f!==!0&&Object.freeze(g),g}return c(K.is(a),"Invalid argument `type` supplied to `list()`"),c(p(B).is(b),"Invalid argument `name` supplied to `list()`"),b=b||f("list(%s)",h(a)),d.meta={kind:"list",type:a,name:b},d.isList=function(b){return b.every(a.is)},d.is=function(a){return E.is(a)&&d.isList(a)},d.update=function(a,b,c){return d(l(a,b,c))},d}function u(a,b,d){function e(f,g){if(c(F.is(f),"Invalid `%s` supplied to `%s`, expected an `Obj`",f,d),e.isDict(f))return f;var h={};for(var i in f)if(f.hasOwnProperty(i)){i=a(i);var j=f[i];h[i]=b(j,g)}return g!==!0&&Object.freeze(h),h}return c(K.is(a),"Invalid argument `domain` supplied to `dict()`"),c(K.is(b),"Invalid argument `codomain` supplied to `dict()`"),c(p(B).is(d),"Invalid argument `name` supplied to `dict()`"),d=d||f("dict(%s, %s)",h(a),h(b)),e.meta={kind:"dict",domain:a,codomain:b,name:d},e.isDict=function(c){for(var d in c)if(c.hasOwnProperty(d)&&(!a.is(d)||!b.is(c[d])))return!1;return!0},e.is=function(a){return F.is(a)&&e.isDict(a)},e.update=function(a,b,c){return e(l(a,b,c))},e}function v(a,b,d){function e(a){return v.is(a)||(a=e.of(a)),c(e.is(a),"Invalid `%s` supplied to `%s`",a,d),a}a=E.is(a)?a:[a],c(t(K).is(a),"Invalid argument `domain` supplied to `func()`"),c(K.is(b),"Invalid argument `codomain` supplied to `func()`"),d=d||f("func([%s], %s)",a.map(h).join(", "),h(b));var g=a.length;return e.meta={kind:"func",domain:a,codomain:b,name:d},e.is=function(c){return v.is(c)&&c.func.domain.length===a.length&&c.func.domain.every(function(b,c){return b===a[c]})&&c.func.codomain===b},e.of=function(d){function f(){var c=y.call(arguments),e=Math.min(c.length,g);if(c=r(a.slice(0,e))(c),e===g){var f=d.apply(this,c);return f=b(f)}var h=Function.prototype.bind.apply(d,[this].concat(c)),i=v(a.slice(e),b);return i.of(h)}return c("function"==typeof d),e.is(d)?d:(f.func={domain:a,codomain:b,f:d},f)},e}var w=!1,x={onFail:a},y=Array.prototype.slice;f.formatters={s:function(a){return String(a)},j:function(a){return JSON.stringify(a,g)}},l.commands={$apply:function(a,b){return c(G.is(a)),a(b)},$push:function(a,b){return c(E.is(a)),c(E.is(b)),b.concat(a)},$remove:function(a,b){c(E.is(a)),c(F.is(b));for(var d=0,e=a.length;e>d;d++)delete b[a[d]];return b},$set:function(a){return a},$splice:function(a,b){return c(t(E).is(a)),c(E.is(b)),a.reduce(function(a,b){return a.splice.apply(a,b),a},b)},$swap:function(a,b){c(F.is(a)),c(C.is(a.from)),c(C.is(a.to)),c(E.is(b));var d=b[a.to];return b[a.to]=b[a.from],b[a.from]=d,b},$unshift:function(a,b){return c(E.is(a)),c(E.is(b)),a.concat(b)}};var z=m("Any",function(){return!0}),A=m("Nil",function(a){return null===a||void 0===a}),B=m("Str",function(a){return"string"==typeof a}),C=m("Num",function(a){return"number"==typeof a&&isFinite(a)&&!isNaN(a)}),D=m("Bool",function(a){return a===!0||a===!1}),E=m("Arr",function(a){return a instanceof Array}),F=m("Obj",function(a){return!A.is(a)&&"object"==typeof a&&!E.is(a)}),G=m("Func",function(a){return"function"==typeof a}),H=m("Err",function(a){return a instanceof Error}),I=m("Re",function(a){return a instanceof RegExp}),J=m("Dat",function(a){return a instanceof Date}),K=m("Type",function(a){return G.is(a)&&F.is(a.meta)});return q.of=function(a,b){a=B.is(a)?a.split(" "):a;var c={};return a.forEach(function(a){c[a]=a}),q(c,b)},v.is=function(a){return G.is(a)&&F.is(a.func)},{util:{mixin:d,merge:e,format:f,getName:h,getKind:i,slice:y,shallowCopy:k,update:l},options:x,assert:c,fail:b,Any:z,Nil:A,Str:B,Num:C,Bool:D,Arr:E,Obj:F,Func:G,Err:H,Re:I,Dat:J,Type:K,irriducible:m,struct:n,enums:q,union:o,maybe:p,tuple:r,subtype:s,list:t,dict:u,func:v}});
!function(a,b){"use strict";"function"==typeof define&&define.amd?define([],b):"object"==typeof exports?module.exports=b():a.t=b()}(this,function(){"use strict";function a(a){throw w=!0,new Error(a)}function b(a){x.onFail(a)}function c(a){if(a!==!0){var c=y.call(arguments,1),d=c[0]?f.apply(null,c):"assert failed";b(d)}}function d(a,b,d){if(A.is(b))return a;for(var e in b)b.hasOwnProperty(e)&&(d||c(!a.hasOwnProperty(e),"cannot overwrite property %s",e),a[e]=b[e]);return a}function e(){return Array.prototype.reduce.call(arguments,function(a,b){return d(a,b,!0)},{})}function f(){function a(a,e){if("%%"===a)return"%";if(d>=c)return a;var g=f.formatters[e];return g?g(b[d++]):a}var b=y.call(arguments),c=b.length,d=1,e=b[0],g=e.replace(/%([a-z%])/g,a);return c>d&&(g+=" "+b.slice(d).join(" ")),g}function g(a,b){return"function"==typeof b?f("Func",b.name):b}function h(a){return c(K.is(a),"Invalid argument `type` of value `%j` supplied to `getName()`, expected a type.",a),a.meta.name}function i(a){return c(K.is(a),"Invalid argument `type` of value `%j` supplied to `geKind()`, expected a type.",a),a.meta.kind}function j(a,b){c(!(a instanceof b),"Operator `new` is forbidden for `%s`",h(b))}function k(a){return E.is(a)?a.concat():F.is(a)?d({},a):a}function l(a,b){c(!A.is(a)),c(F.is(b));var d=k(a);for(var e in b)if(b.hasOwnProperty(e)){if(l.commands.hasOwnProperty(e))return c(1===Object.keys(b).length),l.commands[e](b[e],d);d[e]=l(d[e],b[e])}return d}function m(a,b){function d(e){return j(this,d),c(b(e),"Invalid `%s` supplied to `%s`",e,a),e}return c("string"==typeof a,"Invalid argument `name` supplied to `irriducible()`"),c("function"==typeof b,"Invalid argument `is` supplied to `irriducible()`"),d.meta={kind:"irriducible",name:a},d.is=b,d}function n(a,b){function e(d,f){if(e.is(d))return d;if(c(F.is(d),"Invalid `%s` supplied to `%s`, expected an `Obj`",d,b),!(this instanceof e))return new e(d,f);for(var g in a)if(a.hasOwnProperty(g)){var h=a[g],i=d[g];this[g]=h(i,f)}f!==!0&&Object.freeze(this)}return c(u(B,K).is(a),"Invalid argument `props` supplied to `struct()`"),c(p(B).is(b),"Invalid argument `name` supplied to `struct()`"),b=b||"struct",e.meta={kind:"struct",props:a,name:b},e.is=function(a){return a instanceof e},e.update=function(a,b,c){return new e(l(a,b,c))},e.extend=function(b,c){return n([a].concat(b).reduce(d,{}),c)},e}function o(a,b){function d(a,e){j(this,d),c(G.is(d.dispatch),"unimplemented %s.dispatch()",b);var f=d.dispatch(a);return c(K.is(f),"%s.dispatch() returns no type",b),f(a,e)}c(t(K).is(a),"Invalid argument `types` supplied to `union()`");var e=a.length;return c(e>=2,"Invalid argument `types` supplied to `union()`"),c(p(B).is(b),"Invalid argument `name` supplied to `union()`"),b=b||f("union([%s])",a.map(h).join(", ")),d.meta={kind:"union",types:a,name:b},d.is=function(b){return a.some(function(a){return a.is(b)})},d.dispatch=function(b){for(var c=0,d=a.length;d>c;c++)if(a[c].is(b))return a[c]},d}function p(a,b){function d(b,c){return j(this,d),A.is(b)?null:a(b,c)}return c(K.is(a),"Invalid argument `type` supplied to `maybe()`"),"maybe"===i(a)?a:(c(A.is(b)||B.is(b),"Invalid argument `name` supplied to `maybe()`"),b=b||f("maybe(%s)",h(a)),d.meta={kind:"maybe",type:a,name:b},d.is=function(b){return A.is(b)||a.is(b)},d)}function q(a,b){function d(a){return j(this,d),c(d.is(a),"Invalid `%s` supplied to `%s`, expected one of %j",a,b,e),a}c(F.is(a),"Invalid argument `map` supplied to `enums()`"),c(p(B).is(b),"Invalid argument `name` supplied to `enums()`"),b=b||"enums";var e=Object.keys(a);return d.meta={kind:"enums",map:a,name:b},d.is=function(b){return B.is(b)&&a.hasOwnProperty(b)},d}function r(a,b){function d(f,g){if(c(E.is(f)&&f.length===e,"Invalid `%s` supplied to `%s`, expected an `Arr` of length `%s`",f,b,e),d.isTuple(f))return f;for(var h=[],i=0;e>i;i++){var j=a[i],k=f[i];h.push(j(k,g))}return g!==!0&&Object.freeze(h),h}c(t(K).is(a),"Invalid argument `types` supplied to `tuple()`");var e=a.length;return c(p(B).is(b),"Invalid argument `name` supplied to `tuple()`"),b=b||f("tuple([%s])",a.map(h).join(", ")),d.meta={kind:"tuple",types:a,length:e,name:b},d.isTuple=function(b){return a.every(function(a,c){return a.is(b[c])})},d.is=function(a){return E.is(a)&&a.length===e&&d.isTuple(a)},d.update=function(a,b,c){return d(l(a,b,c))},d}function s(a,b,d){function e(f,h){j(this,e);var i=a(f,h);return c(b(i),"Invalid `%s` supplied to `%s`, %s",f,d,g),i}c(K.is(a),"Invalid argument `type` supplied to `subtype()`"),c(G.is(b),"Invalid argument `predicate` supplied to `subtype()`"),c(p(B).is(d),"Invalid argument `name` supplied to `subtype()`"),d=d||f("subtype(%s)",h(a));var g=b.__doc__||f("insert a valid value for %s",b.name||"the subtype");return e.meta={kind:"subtype",type:a,predicate:b,name:d},e.is=function(c){return a.is(c)&&b(c)},e.update=function(a,b,c){return e(l(a,b,c))},e}function t(a,b){function d(e,f){if(c(E.is(e),"Invalid `%s` supplied to `%s`, expected an `Arr`",e,b),d.isList(e))return e;for(var g=[],h=0,i=e.length;i>h;h++){var j=e[h];g.push(a(j,f))}return f!==!0&&Object.freeze(g),g}return c(K.is(a),"Invalid argument `type` supplied to `list()`"),c(p(B).is(b),"Invalid argument `name` supplied to `list()`"),b=b||f("list(%s)",h(a)),d.meta={kind:"list",type:a,name:b},d.isList=function(b){return b.every(a.is)},d.is=function(a){return E.is(a)&&d.isList(a)},d.update=function(a,b,c){return d(l(a,b,c))},d}function u(a,b,d){function e(f,g){if(c(F.is(f),"Invalid `%s` supplied to `%s`, expected an `Obj`",f,d),e.isDict(f))return f;var h={};for(var i in f)if(f.hasOwnProperty(i)){i=a(i);var j=f[i];h[i]=b(j,g)}return g!==!0&&Object.freeze(h),h}return c(K.is(a),"Invalid argument `domain` supplied to `dict()`"),c(K.is(b),"Invalid argument `codomain` supplied to `dict()`"),c(p(B).is(d),"Invalid argument `name` supplied to `dict()`"),d=d||f("dict(%s, %s)",h(a),h(b)),e.meta={kind:"dict",domain:a,codomain:b,name:d},e.isDict=function(c){for(var d in c)if(c.hasOwnProperty(d)&&(!a.is(d)||!b.is(c[d])))return!1;return!0},e.is=function(a){return F.is(a)&&e.isDict(a)},e.update=function(a,b,c){return e(l(a,b,c))},e}function v(a,b,d){function e(a){return v.is(a)||(a=e.of(a)),c(e.is(a),"Invalid `%s` supplied to `%s`",a,d),a}a=E.is(a)?a:[a],c(t(K).is(a),"Invalid argument `domain` supplied to `func()`"),c(K.is(b),"Invalid argument `codomain` supplied to `func()`"),d=d||f("func([%s], %s)",a.map(h).join(", "),h(b));var g=a.length;return e.meta={kind:"func",domain:a,codomain:b,name:d},e.is=function(c){return v.is(c)&&c.func.domain.length===a.length&&c.func.domain.every(function(b,c){return b===a[c]})&&c.func.codomain===b},e.of=function(d){function f(){var c=y.call(arguments),e=Math.min(c.length,g);if(c=r(a.slice(0,e))(c),e===g){var f=d.apply(this,c);return f=b(f)}var h=Function.prototype.bind.apply(d,[this].concat(c)),i=v(a.slice(e),b);return i.of(h)}return c("function"==typeof d),e.is(d)?d:(f.func={domain:a,codomain:b,f:d},f)},e}var w=!1,x={onFail:a},y=Array.prototype.slice;f.formatters={s:function(a){return String(a)},j:function(a){return JSON.stringify(a,g)}},l.commands={$apply:function(a,b){return c(G.is(a)),a(b)},$push:function(a,b){return c(E.is(a)),c(E.is(b)),b.concat(a)},$remove:function(a,b){c(E.is(a)),c(F.is(b));for(var d=0,e=a.length;e>d;d++)delete b[a[d]];return b},$set:function(a){return a},$splice:function(a,b){return c(t(E).is(a)),c(E.is(b)),a.reduce(function(a,b){return a.splice.apply(a,b),a},b)},$swap:function(a,b){c(F.is(a)),c(C.is(a.from)),c(C.is(a.to)),c(E.is(b));var d=b[a.to];return b[a.to]=b[a.from],b[a.from]=d,b},$unshift:function(a,b){return c(E.is(a)),c(E.is(b)),a.concat(b)}};var z=m("Any",function(){return!0}),A=m("Nil",function(a){return null===a||void 0===a}),B=m("Str",function(a){return"string"==typeof a}),C=m("Num",function(a){return"number"==typeof a&&isFinite(a)&&!isNaN(a)}),D=m("Bool",function(a){return a===!0||a===!1}),E=m("Arr",function(a){return a instanceof Array}),F=m("Obj",function(a){return!A.is(a)&&"object"==typeof a&&!E.is(a)}),G=m("Func",function(a){return"function"==typeof a}),H=m("Err",function(a){return a instanceof Error}),I=m("Re",function(a){return a instanceof RegExp}),J=m("Dat",function(a){return a instanceof Date}),K=m("Type",function(a){return G.is(a)&&F.is(a.meta)});return q.of=function(a,b){a=B.is(a)?a.split(" "):a;var c={};return a.forEach(function(a){c[a]=a}),q(c,b)},v.is=function(a){return G.is(a)&&F.is(a.func)},{util:{mixin:d,merge:e,format:f,getName:h,getKind:i,slice:y,shallowCopy:k,update:l},options:x,assert:c,fail:b,Any:z,Nil:A,Str:B,Num:C,Bool:D,Arr:E,Obj:F,Func:G,Err:H,Re:I,Dat:J,Type:K,irriducible:m,struct:n,enums:q,union:o,maybe:p,tuple:r,subtype:s,list:t,dict:u,func:v}});
//# sourceMappingURL=tcomb.min.js.map

Sorry, the diff of this file is not supported yet

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