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

formact

Package Overview
Dependencies
Maintainers
1
Versions
39
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

formact - npm Package Compare versions

Comparing version 0.10.3 to 0.10.4

12

lib/FormactMe.js

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

fieldValue: _fieldValue,
validate: this.validate
validate: this.validateField
});

@@ -94,3 +94,3 @@

value: _value,
validate: this.validate
validate: this.validateField
});

@@ -145,2 +145,10 @@ this.setState({

this.validateField = function (value) {
var errorMessage = _this2.validate(value);
_this2.setState({
errorMessage: errorMessage
});
return errorMessage;
};
this.propagateValue = function (fieldValue) {

@@ -147,0 +155,0 @@ var props = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : _this2.props;

2

package.json
{
"name": "formact",
"version": "0.10.3",
"version": "0.10.4",
"description": "A React Set of Form Components with Context",

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

@@ -55,3 +55,3 @@ // @flow

fieldValue,
validate: this.validate,
validate: this.validateField,
})

@@ -65,2 +65,10 @@

validateField = (value: FieldValue): string => {
const errorMessage = this.validate(value)
this.setState({
errorMessage,
})
return errorMessage
}
componentWillUnmount() {

@@ -85,3 +93,3 @@ if (this.context && this.context.removeField) {

value,
validate: this.validate,
validate: this.validateField,
})

@@ -88,0 +96,0 @@ this.setState({

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