New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

fefe

Package Overview
Dependencies
Maintainers
1
Versions
25
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

fefe - npm Package Compare versions

Comparing version 3.0.0 to 3.1.0

dist/discriminated-union.d.ts

1

dist/index.d.ts

@@ -8,2 +8,3 @@ export * from './errors';

export * from './date';
export * from './discriminated-union';
export * from './enumerate';

@@ -10,0 +11,0 @@ export * from './map-object-keys';

@@ -20,2 +20,3 @@ "use strict";

__exportStar(require("./date"), exports);
__exportStar(require("./discriminated-union"), exports);
__exportStar(require("./enumerate"), exports);

@@ -22,0 +23,0 @@ __exportStar(require("./map-object-keys"), exports);

2

package.json
{
"name": "fefe",
"version": "3.0.0",
"version": "3.1.0",
"description": "Validate, sanitize and transform values with proper types.",

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

@@ -223,2 +223,12 @@ # fefe

### `discriminatedUnion(key, definition, options?): Validator<ObjectResult<D>>`
Returns a validator that returns `value` if:
* it is an object and
* the `value[key]` is a key of `definition`
* `value` (without `key`) passes the validation as specified in `definition[key]`.
Otherwise it returns an error. A new object is returned that has the results of the validator functions as values.
Options: see `object()`.
### `enumerate(value1, value2, ...): Validator<value1 | value2 | ...>`

@@ -225,0 +235,0 @@

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