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

calidation

Package Overview
Dependencies
Maintainers
1
Versions
34
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

calidation - npm Package Compare versions

Comparing version 1.2.0 to 1.2.1

11

dist/Form.js

@@ -75,3 +75,3 @@ 'use strict';

var fields = _extends({}, _this.state.fields, _defineProperty({}, e.target.name, e.target.value));
var errors = _this.validate(fields);
var errors = _this.validate(fields, _this.state.config);
_this.setState({ errors: errors, fields: fields });

@@ -96,4 +96,4 @@ }, _this.onSubmit = function (e) {

_this.setState({ errors: errors, fields: fields });
}, _this.validate = function (fields) {
return Object.entries(_this.state.config).reduce(function (all, _ref6) {
}, _this.validate = function (fields, config) {
return Object.entries(config).reduce(function (all, _ref6) {
var _ref7 = _slicedToArray(_ref6, 2),

@@ -125,6 +125,5 @@ name = _ref7[0],

var fields = _extends({}, _this.state.fields, initialValues);
var errors = _this.validate(fields, config);
_this.setState({ config: config, fields: fields }, function (nextState) {
return _this.setState({ errors: _this.validate(fields) });
});
_this.setState({ config: config, fields: fields, errors: errors });
}, _this.unregisterSubComponent = function (fieldsToRemove) {

@@ -131,0 +130,0 @@ var keys = Object.keys(fieldsToRemove);

{
"name": "calidation",
"version": "1.2.0",
"version": "1.2.1",
"description": "A red hot validation library for React",

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

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