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 3.0.3 to 3.0.4

README.md

4

dist/index.d.ts

@@ -1,2 +0,2 @@

/// <reference types="react" />
import React from 'react';
declare type ObjectRecord = Record<string, any>;

@@ -65,3 +65,3 @@ export declare type FormSubmitPayload = {

export declare const useField: (props: FieldProps) => FieldPayload;
export declare const turnIntoField: (Component: any, defaultErrorMessages?: DefaultErrorMessages) => (props: FieldProps) => JSX.Element;
export declare const turnIntoField: <ComponentProps extends object>(Component: React.ComponentType<ComponentProps>, defaultErrorMessages?: DefaultErrorMessages) => React.FC<ComponentProps & FieldProps>;
declare type Children = (JSX.Element | null)[] | (JSX.Element | null);

@@ -68,0 +68,0 @@ export declare type FormProps = {

@@ -200,3 +200,3 @@ "use strict";

exports.useForm = useForm;
const REQUIRED_VALIDATION = (errorMessage = 'Required field.') => (value) => (!value ? errorMessage : '');
const REQUIRED_VALIDATION = (errorMessage = 'Required field.') => (value) => !value ? errorMessage : '';
/* eslint-disable */

@@ -203,0 +203,0 @@ exports.EMAIL_REGEX = /^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/;

{
"name": "formact",
"version": "3.0.3",
"version": "3.0.4",
"description": "Context for React form components with validation",
"scripts": {
"build": "tsc",
"start": "nodemon --config nodemon.json src/test.ts",
"flow:install": "flow-typed install --ignoreDeps=dev",
"test": "echo \"Error: no test specified\" && exit 1",

@@ -32,5 +30,4 @@ "ship": "npm run build && npm version patch && npm publish --access public && git push"

"@types/react": "^17.0.19",
"nodemon": "^2.0.12",
"typescript": "^4.4.2"
}
}
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