Security News
Fluent Assertions Faces Backlash After Abandoning Open Source Licensing
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
form-manager-react
Advanced tools
npm i form-manager-react
Prop | Description | Default |
---|---|---|
onSubmit | Function to handle form data | |
validations | A set of functions to validate inputs by name | none |
formStyle | external form style | {} |
styleErrorParagraph | external style for error display | {} |
styleErrorDiv | external style for error container | {} |
classNameErrorDiv | className for error container | none |
classNameErrorParagraph | className for error display | none |
classNameForm | className for form | none |
import React from 'react'
import Form from 'form-manager-react'
const View: React.FC = () => {
return (
<>
<Form
onSubmit={data => {
console.log(data)
}}
styleErrorParagraph={{ color: 'red', fontWeight: 'bold' }}
validations={{
cpf: text => {
const regex =
/^([0-9]{3}\.?[0-9]{3}\.?[0-9]{3}\-?[0-9]{2}|[0-9]{2}\.?[0-9]{3}\.?[0-9]{3}\/?[0-9]{4}\-?[0-9]{2})$/
return regex.test(String(text))
},
}}
>
<div>
<input name="name1" type="text" value="value" />
<div>
<input name="cpf" type="text" value="value" />
</div>
</div>
<button
style={{
backgroundColor: 'blue',
color: 'white',
borderRadius: '16px',
border: 'none',
padding: '8px 16px',
}}
type="submit"
>
Salvar
</button>
</Form>
</>
)
}
export default View
FAQs
## Overview
We found that form-manager-react demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Fluent Assertions is facing backlash after dropping the Apache license for a commercial model, leaving users blindsided and questioning contributor rights.
Research
Security News
Socket researchers uncover the risks of a malicious Python package targeting Discord developers.
Security News
The UK is proposing a bold ban on ransomware payments by public entities to disrupt cybercrime, protect critical services, and lead global cybersecurity efforts.