Skip to content

Commit 8fbdce0

Browse files
author
Robin Schultz
committed
remove console log
1 parent b10fa55 commit 8fbdce0

File tree

3 files changed

+3
-5
lines changed

3 files changed

+3
-5
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -114,14 +114,14 @@ Then you can simply integrate with the default Formik flow.
114114
```typescript jsx
115115
export const Login: FunctionComponent = () => {
116116

117-
const [validate,] = useValidation(LoginValidation);
117+
const [validate, errors] = useValidation(LoginValidation);
118118

119119
return (
120120
<Formik initialValues={{username: '', password: ''}}
121121
validateOnBlur
122122
validateOnChange
123123
validate={validate}>
124-
{({values, errors, touched, handleChange, handleBlur}) => (
124+
{({values, touched, handleChange, handleBlur}) => (
125125
<Form>
126126

127127
<label htmlFor="username">Username</label>

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "react-class-validator",
3-
"version": "1.2.1",
3+
"version": "1.2.2",
44
"description": "React hook for validation with class-validator",
55
"main": "dist/index.js",
66
"scripts": {

src/index.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,8 +51,6 @@ export const useValidation = <T, K extends keyof T>(validationClass: Newable<T>)
5151
[key]: validationErrors[key]
5252
}), {});
5353

54-
console.dir(filteredErrors);
55-
5654
setErrors({
5755
...filteredErrors,
5856
...validation

0 commit comments

Comments
 (0)