🚀 Big News: Socket Acquires Coana to Bring Reachability Analysis to Every Appsec Team.Learn more
Socket
Book a DemoInstallSign in
Socket

@schroffl/json-mapping

Package Overview
Dependencies
Maintainers
1
Versions
17
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@schroffl/json-mapping - npm Package Compare versions

Comparing version

to
0.0.2

14

index.js

@@ -37,2 +37,14 @@ // The export pattern is a UMD template:

/**
* The 'ok' and 'error' wrappers only exist for performance reasons.
* Previously I had an implementation that threw immediately when
* a decoder failed, but that had a hefty impact on the performance
* of Decode.oneOf, because it expects some of it's child decoders
* to fail.
*
* Now we have a separate decodeInternal function which uses the
* result wrappers and a user-exposed decode function which throws
* if the decoder fails.
*/
function ok(value) {

@@ -118,3 +130,3 @@ return { ok: true, value: value };

} else {
return result;
return ok(result);
}

@@ -121,0 +133,0 @@ }

2

package.json
{
"name": "@schroffl/json-mapping",
"version": "0.0.1",
"version": "0.0.2",
"description": "A set of utilites for defining and running conversions between JSON and JavaScript values",

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