Socket
Socket
Sign inDemoInstall

@epistemology-factory/crocks-web

Package Overview
Dependencies
Maintainers
1
Versions
31
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@epistemology-factory/crocks-web - npm Package Compare versions

Comparing version 0.2.5 to 0.2.6

web/lambda/request.js

2

package.json
{
"name": "@epistemology-factory/crocks-web",
"version": "0.2.5",
"version": "0.2.6",
"description": "Functions to help write web applications with crocks",

@@ -5,0 +5,0 @@ "scripts": {

@@ -5,6 +5,13 @@ "use strict";

const chain = require("crocks/pointfree/chain");
const compose = require("crocks/helpers/compose");
const contramap = require("crocks/pointfree/contramap");
const curry = require("crocks/helpers/curry");
const ifElse = require("crocks/logic/ifElse");
const flip = require("crocks/combinators/flip");
const pipe = require("crocks/helpers/pipe");
const reduce = require("crocks/pointfree/reduce");
const { applyFunctor } = require("@epistemology-factory/crocks-ext/helpers");
// makeValidator :: (a -> Boolean) -> ([ String ] -> a -> ValidationFailure) -> [ String ] -> a -> Result ValidationFailure a

@@ -19,4 +26,13 @@ const makeValidator = curry((pred, err) => (path) =>

// validators :: Foldable f => f -> [ String ] -> a -> Result ValidationFailure a
const validators = (...validators) =>
pipe(
applyFunctor(validators),
flip(reduce(flip(chain))),
contramap(Result.Ok)
)
module.exports = {
makeValidator
makeValidator,
validators
}
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